I'm trying to install semantic-ui locally on my device but I keep getting the following deprecation errors and the installation process keep terminating.
npm WARN deprecated gulp-util#3.0.8: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
npm WARN deprecated resolve-url#0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix#0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated minimatch#2.0.10: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated minimatch#0.2.14: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated graceful-fs#1.2.3: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
npm WARN deprecated natives#1.1.6: This module relies on Node.js's internals and will break at some point. Do not use it, and update to graceful-fs#4.x.
npm WARN deprecated chokidar#2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN deprecated fsevents#1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
> semantic-ui#2.4.2 install C:\Users\USER\Desktop\Education\uni\questions\node_modules\semantic-ui
> gulp install
fs.js:45
} = primordials;
^
ReferenceError: primordials is not defined
at fs.js:45:5
at req_ (C:\Users\USER\Desktop\Education\uni\questions\node_modules\natives\index.js:143:24)
at Object.req [as require] (C:\Users\USER\Desktop\Education\uni\questions\node_modules\natives\index.js:55:10)
at Object.<anonymous> (C:\Users\USER\Desktop\Education\uni\questions\node_modules\vinyl-fs\node_modules\graceful-fs\fs.js:1:37)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Module.load (internal/modules/cjs/loader.js:928:32)
at Function.Module._load (internal/modules/cjs/loader.js:769:14)
at Module.require (internal/modules/cjs/loader.js:952:19)
at require (internal/modules/cjs/helpers.js:88:18)
npm WARN rollback Rolling back source-map#0.6.1 failed (this is probably harmless): EPERM: operation not permitted, lstat 'C:\Users\USER\Desktop\Education\uni\questions\node_modules\concat-with-sourcemaps\node_modules'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#^1.2.7 (node_modules\gulp-copy\node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#^1.2.7 (node_modules\gulp-watch\node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN questions#1.0.0 No repository field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#2.1.3 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! semantic-ui#2.4.2 install: `gulp install`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the semantic-ui#2.4.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\USER\AppData\Roaming\npm-cache\_logs\2020-11-29T01_27_16_929Z-debug.log
C:\Users\USER\Desktop\Education\uni\questions>
When I try to install mongoose, I still get the error below:
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\USER\AppData\Roaming\npm-cache\_logs\2020-11-29T01_27_16_929Z-debug.log
Please, how do I get rid of this error?
Related
I get the following error when trying to install semantic-ui via npm for fresh project.
$ node -v
v16.14.0
$ npm -v
8.10.0
$ npm i semantic-ui
npm WARN deprecated source-map-url#0.4.1: See https://github.com/lydell/source-map-url#deprecated
npm WARN deprecated urix#0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated resolve-url#0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated source-map-resolve#0.5.3: See https://github.com/lydell/source-map-resolve#deprecated
npm WARN deprecated gulp-util#3.0.8: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
npm WARN deprecated chokidar#2.1.8: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependencies
npm ERR! code 1
npm ERR! path /home/indikau/workspace/learning/web_design/semantic_ui/Tutorial/13_theming/node_modules/semantic-ui
npm ERR! command failed
npm ERR! command sh -c gulp install
npm ERR! Error [ERR_REQUIRE_ESM]: require() of ES Module /home/indikau/workspace/learning/web_design/semantic_ui/Tutorial/13_theming/node_modules/del/index.js from /home/indikau/workspace/learning/web_design/semantic_ui/Tutorial/13_theming/node_modules/semantic-ui/tasks/clean.js not supported.
npm ERR! Instead change the require of index.js in /home/indikau/workspace/learning/web_design/semantic_ui/Tutorial/13_theming/node_modules/semantic-ui/tasks/clean.js to a dynamic import() which is available in all CommonJS modules.
npm ERR! at Object.<anonymous> (/home/indikau/workspace/learning/web_design/semantic_ui/Tutorial/13_theming/node_modules/semantic-ui/tasks/clean.js:8:12)
npm ERR! at Object.<anonymous> (/home/indikau/workspace/learning/web_design/semantic_ui/Tutorial/13_theming/node_modules/semantic-ui/gulpfile.js:21:18)
npm ERR! at async Promise.all (index 0) {
npm ERR! code: 'ERR_REQUIRE_ESM'
npm ERR! }
npm ERR! A complete log of this run can be found in:
npm ERR! /home/indikau/.npm/_logs/2022-10-20T01_40_53_411Z-debug-0.log
This is related to the del package being updated to ESM-only. You can fix this by forcing a resolution of del#6.1 (rather than 7.x) in your package.json.
I use yarn which has this built in. I believe you must use a package like this for npm https://github.com/rogeriochaves/npm-force-resolutions.
I ran this script -> npm i --save-dev puppeteer to install puppeteer for e2e testing purposes.
But there is an error while installing:
C:\Users\Mora\Desktop\JS\Testing>npm i --save-dev puppeteer
> puppeteer#13.1.3 install C:\Users\Mora\Desktop\JS\Testing\node_modules\puppete
er
> node install.js
ERROR: Failed to set up Chromium r950341! Set "PUPPETEER_SKIP_DOWNLOAD" env vari
able to skip download.
Error: Download failed: server returned code 403. URL: https://storage.googleapi
s.com/chromium-browser-snapshots/Win/950341/chrome-win.zip
at C:\Users\Mora\Desktop\JS\Testing\node_modules\puppeteer\lib\cjs\puppeteer
\node\BrowserFetcher.js:367:27
at ClientRequest.requestCallback (C:\Users\Mora\Desktop\JS\Testing\node_modu
les\puppeteer\lib\cjs\puppeteer\node\BrowserFetcher.js:493:13)
at Object.onceWrapper (events.js:483:26)
at ClientRequest.emit (events.js:376:20)
at HTTPParser.parserOnIncomingClient (_http_client.js:647:27)
at HTTPParser.parserOnHeadersComplete (_http_common.js:126:17)
at TLSSocket.socketOnData (_http_client.js:515:22)
at TLSSocket.emit (events.js:376:20)
at addChunk (internal/streams/readable.js:309:12)
at readableAddChunk (internal/streams/readable.js:284:9)
npm WARN js-testing-introduction#1.0.0 No repository field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#2.3.2 (node_modules\fse
vents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#
2.3.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"ia32"
})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.13 (node_modules\wa
tchpack-chokidar2\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#
1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"ia32
"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! puppeteer#13.1.3 install: `node install.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the puppeteer#13.1.3 install script.
npm ERR! This is probably not a problem with npm. There is likely additional log
ging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Mora\AppData\Roaming\npm-cache\_logs\2022-02-06T10_19_25_3
69Z-debug.log
How can i fix this?
It looks like it is not able to download chromium from https://storage.googleapis.com/chromium-browser-snapshots/Win/950341/chrome-win.zip.
Check whether your network is e.g behind a proxy or storage.googleapis.com was blocked by the firewall.
// do not install a puppeteer
ran this script -> npm install --ignore-scripts puppeteer
I'm a newbie in gatsby, everytime I try to create a gatsby site I am getting this error:
Error: Command failed with exit code 1: npm install
I tried this :
$ gatsby new gatsby-simplefolio https://github.com/cobidev/gatsby-simplefolio
I'm using Windows 10, node -v14.14.0, npm -v6.14.8, Gatsby CLI version: 2.12.109
Result:
$ gatsby new gatsby-simplefolio-2 https://github.com/cobidev/gatsby-simplefolio
info Creating new site from git: https://github.com/cobidev/gatsby-simplefolio.git
Cloning into 'gatsby-simplefolio-2'...
remote: Enumerating objects: 70, done.
remote: Counting objects: 100% (70/70), done.
remote: Compressing objects: 100% (58/58), done.
remote: Total 70 (delta 3), reused 48 (delta 0), pack-reused 0
Unpacking objects: 100% (70/70), 7.24 MiB | 528.00 KiB/s, done.
?[32msuccess?[39m Created starter directory layout
?[34minfo?[39m Installing packages...
npm WARN deprecated request#2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated #hapi/joi#15.1.1: joi is leaving the #hapi organization and moving back to 'joi' (https://github.com/sideway/joi/issues/2411)
npm WARN deprecated eslint-loader#2.2.1: This loader has been deprecated. Please use eslint-webpack-plugin
npm WARN deprecated har-validator#5.1.5: this library is no longer supported
npm WARN deprecated #hapi/bourne#1.3.2: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated #hapi/address#2.1.4: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated #hapi/topo#3.1.6: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated #hapi/hoek#8.5.1: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated chokidar#2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN deprecated #hapi/formula#2.0.0: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated fsevents#1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN deprecated core-js#2.6.11: core-js#<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version
of core-js#3.
npm WARN deprecated resolve-url#0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix#0.1.0: Please see https://github.com/lydell/urix#deprecated
> bufferutil#4.0.1 install C:\Users\Abhik\Documents\Gatsby Practice & Projects\gatsby-simplefolio-2\node_modules\bufferutil
> node-gyp-build
'Projects\gatsby-simplefolio-2\node_modules\.bin\' is not recognized as an internal or external command,
operable program or batch file.
internal/modules/cjs/loader.js:883
throw err;
^
Error: Cannot find module 'C:\Users\Abhik\Documents\node-gyp-build\bin.js'
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: []
}
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#^1.2.7 (node_modules\babel-plugin-add-module-exports\node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#~2.1.2 (node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN notsup Unsupported engine for watchpack-chokidar2#2.0.0: wanted: {"node":"<8.10.0"}
(current: {"node":"14.14.0","npm":"6.14.8"})
npm WARN notsup Not compatible with your version of node/npm: watchpack-chokidar2#2.0.0
npm WARN bootstrap#4.5.3 requires a peer of jquery#1.9.1 - 3 but none is installed. You must
install peer dependencies yourself.
npm WARN bootstrap#4.5.3 requires a peer of popper.js#^1.16.1 but none is installed. You must install peer dependencies yourself.
npm WARN #typescript-eslint/eslint-plugin#2.34.0 requires a peer of eslint#^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN #typescript-eslint/parser#2.34.0 requires a peer of eslint#^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-react-app#5.2.1 requires a peer of eslint#6.x but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-react-app#5.2.1 requires a peer of eslint-plugin-react-hooks#1.x || 2.x but none is installed. You must install peer dependencies yourself.
npm WARN eslint-loader#2.2.1 requires a peer of eslint#>=1.6.0 <7.0.0 but none is installed.
You must install peer dependencies yourself.
npm WARN tsutils#3.17.1 requires a peer of typescript#>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta but none is installed. You must install peer dependencies yourself.
npm WARN acorn-dynamic-import#4.0.0 requires a peer of acorn#^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN theme-ui#0.2.52 requires a peer of #mdx-js/react#^1.0.0 but none is installed. You must install peer dependencies yourself.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! bufferutil#4.0.1 install: `node-gyp-build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bufferutil#4.0.1 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Abhik\AppData\Roaming\npm-cache\_logs\2020-10-19T12_48_11_989Z-debug.log
ERROR
Command failed with exit code 1: npm install
Error: Command failed with exit code 1: npm install
- error.js:56 makeError
[npm]/[gatsby-cli]/[execa]/lib/error.js:56:11
- index.js:114 handlePromise
[npm]/[gatsby-cli]/[execa]/index.js:114:26
- task_queues.js:93 processTicksAndRejections
internal/process/task_queues.js:93:5
- init-starter.js:142 install
[npm]/[gatsby-cli]/lib/init-starter.js:142:7
- init-starter.js:209 clone
[npm]/[gatsby-cli]/lib/init-starter.js:209:3
- init-starter.js:350 initStarter
[npm]/[gatsby-cli]/lib/init-starter.js:350:5
- create-cli.js:430
[npm]/[gatsby-cli]/lib/create-cli.js:430:7
npm WARN deprecated request#2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: #expo/traveling-fastlane-darwin#1.13.1 (node_modules\expo-cli\node_modules#expo\traveling-fastlane-darwin):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for #expo/traveling-fastlane-darwin#1.13.1: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"ia32"})
npm ERR! Unexpected end of JSON input while parsing near '...__joi-15.0.0.tgz","
fi'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\IBDAC\AppData\Roaming\npm-cache_logs\2020-04-08T01_09_04_839Z-debug.log
My system configuration:
debian 4.4 ,
nvm 0.33.8 ,
node v8.9.4 ,
npm 5.6.0 .
I want to install Angular-cli npm install -g #angular/cli.
But I get an error message:
root#contracts:/home/kalugin# npm install -g #angular/cli
/root/.nvm/versions/node/v8.9.4/bin/ng -> /root/.nvm/versions/node/v8.9.4/lib/node_modules/#angular/cli/bin/ng
> node-sass#4.7.2 install /root/.nvm/versions/node/v8.9.4/lib/node_modules/#angular/cli/node_modules/node-sass
> node scripts/install.js
module.js:471
throw err;
^
Error: Cannot find module '/root/.nvm/versions/node/v8.9.4/lib/node_modules/#angular/cli/node_modules/node-sass/scripts/install.js'
at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:394:7)
at startup (bootstrap_node.js:149:9)
at bootstrap_node.js:509:3
> uglifyjs-webpack-plugin#0.4.6 postinstall /root/.nvm/versions/node/v8.9.4/lib/node_modules/#angular/cli/node_modules/webpack/node_modules/uglifyjs-webpack-plugin
> node lib/post_install.js
module.js:471
throw err;
^
Error: Cannot find module '/root/.nvm/versions/node/v8.9.4/lib/node_modules/#angular/cli/node_modules/webpack/node_modules/uglifyjs-webpack-plugin/lib/post_install.js'
at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:394:7)
at startup (bootstrap_node.js:149:9)
at bootstrap_node.js:509:3
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.1.3 (node_modules/#angular/cli/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: node-sass#4.7.2 (node_modules/#angular/cli/node_modules/node-sass):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: node-sass#4.7.2 install: `node scripts/install.js`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! uglifyjs-webpack-plugin#0.4.6 postinstall: `node lib/post_install.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the uglifyjs-webpack-plugin#0.4.6 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-02-09T17_27_50_397Z-debug.log
I tried npm cache clean, doesn't help.
I tried change node version nvm use v6.12.3, doesn't help.
debug.log pointed to the problem with node-sass package.
I tried install node-sass globally - but the same error. I cannot install node-sass...
Any ideas?
Likely the problem is because you're running as root, and NPM disables scripts automatically when you do that. Try passing the --unsafe-perm to the NPM install command
Try npm rebuild node-sass it can be a handy one
Actually the problem is due to use of sudo in command as it is disabling the scripts. Try npm install -g angular-cli without sudo it will work