npm ci command throws error in client directory

4612
12
Jump to solution
12-12-2023 11:21 AM
JaredPilbeam2
MVP Regular Contributor

Currently I'm running Node.js v. 18.18.2 as suggested in this post with ExB v. 1.13. The command npm ci runs without error in the server directory. It errors in the client directory. I've already tried with the latest Node.js v. 20.1.0. No difference.  

C:\WINDOWS\system32>cd C:\ArcGISExperienceBuilder\client

C:\ArcGISExperienceBuilder\client>npm ci
npm ERR! code EUSAGE
npm ERR!
npm ERR! The `npm ci` command can only install with an existing package-lock.json or
npm ERR! npm-shrinkwrap.json with lockfileVersion >= 1. Run an install with npm@5 or
npm ERR! later to generate a package-lock.json file, then try again.
npm ERR!
npm ERR! Clean install a project
npm ERR!
npm ERR! Usage:
npm ERR! npm ci
npm ERR!
npm ERR! Options:
npm ERR! [--install-strategy <hoisted|nested|shallow|linked>] [--legacy-bundling]
npm ERR! [--global-style] [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]]
npm ERR! [--strict-peer-deps] [--foreground-scripts] [--ignore-scripts] [--no-audit]
npm ERR! [--no-bin-links] [--no-fund] [--dry-run]
npm ERR! [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]]
npm ERR! [-ws|--workspaces] [--include-workspace-root] [--install-links]
npm ERR!
npm ERR! aliases: clean-install, ic, install-clean, isntall-clean
npm ERR!
npm ERR! Run "npm help ci" for more info

 

It was suggested in my earlier post  to run these commands, but they make no difference.

//Turns off ssl
npm set strict-ssl false
//Installs node packages
npm ci
//Turns ssl back on for future protection
npm set strict-ssl true

 

During this attempted installation of Node.js I checked the Chocolatey box when installing as suggested by an ESRI tech over the phone. I guess I can uninstall then reinstall leaving that unchecked. The guide pretty much leaves you hanging here.

12 Replies
Brian_McLeer
Occasional Contributor II

@JaredPilbeam2 , during your install after running npm ci, did you encounter the slash just spinning for a long time with no error messages? I have been encountering this today and posted a question about it. 

https://community.esri.com/t5/arcgis-experience-builder-questions/npm-ci-does-not-progress/m-p/14979...

Brian
0 Kudos
JaredPilbeam2
MVP Regular Contributor

Hi @Brian_McLeer ,

I don't recall, sorry. You say you installed it in the Program Files (x86) directory? In the command prompt when you do step #9, are you sure you're running the npm ci command in that directory? My install is here: C:\arcgis-experience-builder-1.14, for what it's worth.

0 Kudos
Brian_McLeer
Occasional Contributor II

I found the fix from this article below, I had to run 

npm config set strict-ssl false

 

https://community.esri.com/t5/arcgis-experience-builder-questions/cross-env-is-not-recognized-as-an-...

Brian
0 Kudos