at createEsmNotFoundErr (node:internal/modules/cjs/loader:1098:15)
at finalizeEsmResolution (node:internal/modules/cjs/loader:1091:15)
at resolveExports (node:internal/modules/cjs/loader:567:14)
at Module._findPath (node:internal/modules/cjs/loader:636:31)
at Module._resolveFilename (node:internal/modules/cjs/loader:1063:27)
at Module._load (node:internal/modules/cjs/loader:922:27)
at Module.require (node:internal/modules/cjs/loader:1143:19)
at require (node:internal/modules/cjs/helpers:121:18)
at Object.<anonymous> (C:\Users\AppData\Roaming\npm\node_modules\npm\node_modules\gauge\lib\index.js:5:14)
at Module._compile (node:internal/modules/cjs/loader:1256:14) {
code: ‘MODULE_NOT_FOUND’,
I can however see that newman is installed
C:>newman --version
5.3.2
I am also able to run collection files successfully through Newman
When I install HTML reporter package with the command
npm install -g newman-reporter-htmlextra, I get the error
at createEsmNotFoundErr (node:internal/modules/cjs/loader:1098:15)
at finalizeEsmResolution (node:internal/modules/cjs/loader:1091:15)
at resolveExports (node:internal/modules/cjs/loader:567:14)
at Module._findPath (node:internal/modules/cjs/loader:636:31)
at Module._resolveFilename (node:internal/modules/cjs/loader:1063:27)
at Module._load (node:internal/modules/cjs/loader:922:27)
at Module.require (node:internal/modules/cjs/loader:1143:19)
at require (node:internal/modules/cjs/helpers:121:18)
at Object.<anonymous> (C:\Users\AppData\Roaming\npm\node_modules\npm\node_modules\gauge\lib\index.js:5:14)
at Module._compile (node:internal/modules/cjs/loader:1256:14) {
Use a Node Version Manager: Sometimes, different projects require different Node versions. Using a Node Version Manager like nvm-windows for Windows might help. With it, you can easily switch between Node versions, which might alleviate some of these issues.
Check for any antivirus or firewall restrictions: Sometimes these can interfere with installations, especially when installing global npm modules. If you have any active, try temporarily disabling them and repeating the installation process.
Uninstalling and Re-installing did not help either. Getting previous errors
I do have antivirus and firewall restrictions, not disables yet as my computer is connected to a network.
command npm -v is giving me the message:
C:\Users\AppData\Roaming\npm\node_modules\npm\lib\cli.js:48
throw err
^
Error: Cannot find module ‘C:\Users\AppData\Roaming\npm\node_modules\npm\node_modules\glob\dist\cjs\src\index.js’
at createEsmNotFoundErr (node:internal/modules/cjs/loader:1098:15)
at finalizeEsmResolution (node:internal/modules/cjs/loader:1091:15)
at resolveExports (node:internal/modules/cjs/loader:567:14)
at Module._findPath (node:internal/modules/cjs/loader:636:31)
at Module._resolveFilename (node:internal/modules/cjs/loader:1063:27)
at Module._load (node:internal/modules/cjs/loader:922:27)
at Module.require (node:internal/modules/cjs/loader:1143:19)
at require (node:internal/modules/cjs/helpers:121:18)
at Object. (C:\Users\pooja\AppData\Roaming\npm\node_modules\npm\node_modules\cacache\lib\util\glob.js:4:24)
at Module._compile (node:internal/modules/cjs/loader:1256:14) {
code: ‘MODULE_NOT_FOUND’,
path: ‘C:\Users\AppData\Roaming\npm\node_modules\npm\node_modules\glob\package.json’
}
It’s more than likely related to the version of node that you’re running. As the reporter is getting slightly old now and it’s not been kept inline with all the node versions that have been released, I suspect that there is something in there that’s not compatible with version 18.
Have you tried this with a different version of node? Using the Node Package Manager is the easiest way, that I’ve found, to switch between different node versions.
Feels like we’re having the same conversation twice
Not really sure what to suggest from here, like I mentioned on the issue you raised on the repo - The reporter is heavily downloaded each week and I haven’t had any installation based issues reported to me, that only leads me to suspect that it’s an environmental problem on your side.
I’m happy to be wrong here though, the last thing I want is someone not being able to use the reporter.
As you mentioned in the issue, the same thing is happening with other custom reporters so it strongly suggests that it’s an environmental issue with your machine.