Getting error "internal/modules/cjs/loader.js:883"when running the now-cli -develop
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-28-2020 09:55 PM
Hi All,
I am trying to develop the comment from my location machine for that i have to install the nmp and now cli in my location machine but then I am running the below code I am getting the below error.
Command: now-cli develop
Error :
C:\SnowDoctor>now-cli develop
Running component locally...
internal/modules/cjs/loader.js:883
throw err;
^
Error: Cannot find module 'C:\SnowDoctor\node_modules\@servicenow\cli-component-archetype-dev\conf\develop\pre\run'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:880:15)
at Function.Module._load (internal/modules/cjs/loader.js:725:27)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
at internal/main/run_main_module.js:17:47 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
[builder:builder-core:end:4768] Task: run develop:pre, Error: Command failed: cmd /d /s /c node node_modules/@servicenow/cli-component-archetype-dev/conf/develop/pre/run
[builder:builder-core:end:10612] Task: run develop:trace, Error: Command failed: cmd /d /s /c builder run develop:pre
Thanks
Ramesh R

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2020 01:56 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2020 02:14 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2020 10:03 AM
Hi
That is interesting.
I do not know all the dependencies yet, but I am trying to find out the root cause.
As said, I had similar issues, and installed the following Software AGAIN in the following order:
> GIT
> NODE with NPM
> NOW-CLI
AFTER THAT, I created a "brand-new" project and called the "npm install" after doing the scaffolding.
That finally solved my issue, so something with these dependencies sorted this out.
Maybe (I know, this may be annoying, but maybe it also solves your issue) you can try this in THAT order (WITH a NEW Project please) on your machine.
I hope this will help also on your computer.
I am very interested in learning about the dependencies, existing.
Good luck!
Please let me know, if that gave some success.
BR
Dirk

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-27-2021 07:38 AM
Did anyone found the root cause?