Describe the bug
When audit reads out the npm configuration, it fails if you have boolean properties in the .npmrc configuration:
❌ Failed: str.replace is not a function
TypeError: str.replace is not a function
at replaceEnvVars (/home/user/.nvm/versions/node/v18.6.0/lib/node_modules/@sandworm/audit/src/registry.js:10:14)
at /home/user/.nvm/versions/node/v18.6.0/lib/node_modules/@sandworm/audit/src/registry.js:19:28
at Array.forEach (<anonymous>)
at getRegistriesInfo (/home/user/.nvm/versions/node/v18.6.0/lib/node_modules/@sandworm/audit/src/registry.js:18:27)
at loadRegistriesInfo (/home/user/.nvm/versions/node/v18.6.0/lib/node_modules/@sandworm/audit/src/registry.js:71:20)
at setupRegistries (/home/user/.nvm/versions/node/v18.6.0/lib/node_modules/@sandworm/audit/src/registry.js:75:3)
at getReport (/home/user/.nvm/versions/node/v18.6.0/lib/node_modules/@sandworm/audit/src/index.js:44:9)
at exports.handler (/home/user/.nvm/versions/node/v18.6.0/lib/node_modules/@sandworm/audit/src/cli/cmds/audit.js:164:15)
Manifest files
Just add a boolean configuration property to your .npmrc file:
always-auth=false
To Reproduce
Just add a boolean configuration property to your .npmrc file:
always-auth=false
Expected behavior
Sandworm-audit should parse AND respect the available configuration settings from the different package managers. But at least from npm.
System (please complete the following information):
Node Version [v18.6.0]
Package Manager [npm]
Package Manager Version [8.19.2]
OS: [Ubuntu 22.04, WSL2]
Additional context
Add any other context about the problem here.
Sandworm version 1.36.0
Describe the bug When audit reads out the npm configuration, it fails if you have boolean properties in the
.npmrc
configuration:Manifest files Just add a boolean configuration property to your
.npmrc
file:To Reproduce Just add a boolean configuration property to your
.npmrc
file:Expected behavior Sandworm-audit should parse AND respect the available configuration settings from the different package managers. But at least from
npm
.System (please complete the following information):
Additional context Add any other context about the problem here.