Select to view content in your preferred language

Issue Installing NPM on Server for ArcGIS Experience Builder Developer Edition

165
2
05-28-2024 11:24 AM
SciotoCoJT
New Contributor II

Hello, I am having a 4058 error code during installation. After doing all of the standard troubleshooting for the issue (Delete the package-lock.json, reinstall, restart, switch arcGIS experience builder versions, switch node.js versions, etc., global installation) I cannot get it to run npm install or npm ci on the folder directory. Here are the logs

0 verbose cli D:\nodejs\node.exe D:\nodejs\node_modules\npm\bin\npm-cli.js
1 info using npm@10.7.0
2 info using node@v18.20.3
3 silly config:load:file:D:\nodejs\node_modules\npm\npmrc
4 silly config:load:file:D:\ArcGISExperienceBuilder\.npmrc
5 silly config:load:file:C:\Users\username\.npmrc
6 silly config:load:file:C:\Users\username\AppData\Roaming\npm\etc\npmrc
7 verbose title npm start
8 verbose argv "start"
9 verbose logfile logs-max:10 dir:C:\Users\username\AppData\Local\npm-cache\_logs\2024-05-28T17_05_35_716Z-
10 verbose logfile C:\Users\username\AppData\Local\npm-cache\_logs\2024-05-28T17_05_35_716Z-debug-0.log
11 silly logfile start cleaning logs, removing 1 files
12 verbose stack Error: Could not read package.json: Error: ENOENT: no such file or directory, open 'D:\ArcGISExperienceBuilder\package.json'
13 verbose cwd D:\ArcGISExperienceBuilder
14 verbose Windows_NT 10.0.20348
15 verbose node v18.20.3
16 verbose npm v10.7.0
17 error code ENOENT
18 error syscall open
19 error path D:\ArcGISExperienceBuilder\package.json
20 error errno -4058
21 error enoent Could not read package.json: Error: ENOENT: no such file or directory, open 'D:\ArcGISExperienceBuilder\package.json'
22 error enoent This is related to npm not being able to find a file.
22 error enoent
23 verbose exit -4058
24 verbose code -4058
25 error A complete log of this run can be found in: C:\Users\username\AppData\Local\npm-cache\_logs\2024-05-28T17_05_35_716Z-debug-0.log

0 Kudos
2 Replies
TimWestern
Occasional Contributor

So I have seen some weird things from time to time with npm.  Usually fresh folder install fixes things.

The logs you post mention folders with files that end in debug-0.log

did you open those and see what they said?  They might give you an idea if it was a particular package at issue.

One more thing... it says you were running this in:

12 verbose stack Error: Could not read package.json: Error: ENOENT: no such file or directory, open 'D:\ArcGISExperienceBuilder\package.json'

Two thoughts.  1 do you the D : indicates this is an additional hard drive or mounted drive, and 2, its saying package.json doesn't exist there.

If you did a fresh unzip you should find package.json in either the client or server sub folders/directories  and it should be in one of those folders that you run npm install or npm ci

Try running inside the server directory first, as is outlined in the setup instructions here: https://developers.arcgis.com/experience-builder/guide/install-guide/  (first step 9)

0 Kudos
JanSarata
Esri Contributor

Are you able to install ArcGIS Experience Builder Developer edition on different machine? If yes, you can try copy paste node-modules folders for both /client and /server, then just npm start for both.

0 Kudos