get error from npm when i tried to install parcel - javascript

i do a project on nodejs with express and mongodb
so i tried to install parcel but i get this error
npm WARN deprecated stable#0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility
npm ERR! code 1
npm ERR! path C:\Users\Downloads\4-natours\aftersection12\node_modules\lmdb
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node-gyp-build-optional-packages
npm ERR! Invalid parameter - 2020\complete-node-bootcamp-master\4-natours\aftersection12\node_modules\.bin\
npm ERR! node:internal/modules/cjs/loader:988
npm ERR! throw err;
npm ERR! ^
npm ERR!
npm ERR! Error: Cannot find module 'C:\Users\5MATA\Downloads\node-gyp-build-optional-packages\bin.js'
npm ERR! at Function.Module._resolveFilename (node:internal/modules/cjs/loader:985:15)
npm ERR! at Function.Module._load (node:internal/modules/cjs/loader:833:27)
npm ERR! at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
npm ERR! at node:internal/main/run_main_module:22:47 {
npm ERR! code: 'MODULE_NOT_FOUND',
npm ERR! requireStack: []
npm ERR! }
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\5MATA\AppData\Local\npm-cache\_logs\2022-11-12T19_37_39_027Z-debug-0.log
whet i can do to solve this error

Related

Got an error while installing react router can anyone solve my problem?

I have this error
D:\>npm install react-router-dom
npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.
npm ERR! code EPERM
npm ERR! syscall mkdir
npm ERR! path D:\
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, mkdir 'D:\'
npm ERR! [Error: EPERM: operation not permitted, mkdir 'D:\'] {
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'mkdir',
npm ERR! path: 'D:\\'
npm ERR! }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It's possible that the file was already in use (by a text editor or antivirus),
npm ERR! or that you lack permissions to access it.
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.
npm ERR! A complete log of this run can be found in:
npm ERR! D:\my-app\AppData\Roaming\npm-cache\_logs\2022-08-07T07_21_15_220Z-debug-0.log
It is a permission Issue.
You're running this command as a non-administrator user.
Open cmd as an administrator
and run this command,
It will work

NPM Error: Cannot find module 'node-bin-darwin-arm64/package.json' fixes on the internet not working

I tried node V16 and V17 from the website, from n and from nvm with arch. I deleted the node_modules folder, but nothing.
I'm using a M1 macbook pro
Error when running npm i:
npm ERR! code 1
npm ERR! path /Users/redacted/Library/CloudStorage/OneDrive-Personal/Software/Code/Discord-Bots/DijkendamDiscordBot/node_modules/node
npm ERR! command failed
npm ERR! command sh -c node installArchSpecificPackage
npm ERR! npm ERR! code ETARGET
npm ERR! npm ERR! notarget No matching version found for node-darwin-arm64#16.13.2.
npm ERR! npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! npm ERR! notarget a package version that doesn't exist.
npm ERR!
npm ERR! npm ERR! A complete log of this run can be found in:
npm ERR! npm ERR! /Users/redacted/.npm/_logs/2022-02-11T23_06_22_932Z-debug-0.log
npm ERR! node:internal/modules/cjs/loader:936
npm ERR! throw err;
npm ERR! ^
npm ERR!
npm ERR! Error: Cannot find module 'node-bin-darwin-arm64/package.json'
npm ERR! Require stack:
npm ERR! - /Users/redacted/Library/CloudStorage/OneDrive-Personal/Software/Code/Discord-Bots/DijkendamDiscordBot/node_modules/node/installArchSpecificPackage.js
npm ERR! at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
npm ERR! at Function.resolve (node:internal/modules/cjs/helpers:108:19)
npm ERR! at ChildProcess.<anonymous> (/Users/redacted/Library/CloudStorage/OneDrive-Personal/Software/Code/Discord-Bots/DijkendamDiscordBot/node_modules/node-bin-setup/index.js:19:27)
npm ERR! at ChildProcess.emit (node:events:520:28)
npm ERR! at maybeClose (node:internal/child_process:1092:16)
npm ERR! at Process.ChildProcess._handle.onexit (node:internal/child_process:302:5) {
npm ERR! code: 'MODULE_NOT_FOUND',
npm ERR! requireStack: [
npm ERR! '/Users/redacted/Library/CloudStorage/OneDrive-Personal/Software/Code/Discord-Bots/DijkendamDiscordBot/node_modules/node/installArchSpecificPackage.js'
npm ERR! ]
npm ERR! }
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/redacted/.npm/_logs/2022-02-11T23_06_18_606Z-debug-0.log
Please help i have tried everything i could find!

I created a project with create-react-app. on my windows pc but when is try to run npm start on the command line it shows this error.please help me

Got an error on npm start
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the raber-react#0.1.0 start 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\lectriweb\AppData\Roaming\npm-cache\_logs\2020-08-17T09_32_32_695Z-debug.log
PS C:\Users\lectriweb\Documents\raber-react> npm start
> raber-react#0.1.0 start C:\Users\lectriweb\Documents\raber-react
> react-scripts start
internal/modules/cjs/loader.js:968
throw err;
^
Error: Cannot find module 'emojis-list'
Require stack:
- C:\Users\lectriweb\Documents\raber-react\node_modules\loader-utils\lib\interpolateName.js
- C:\Users\lectriweb\Documents\raber-react\node_modules\loader-utils\lib\index.js
- C:\Users\lectriweb\Documents\raber-react\node_modules\html-webpack-plugin\index.js
- C:\Users\lectriweb\Documents\raber-react\node_modules\react-scripts\config\webpack.config.js
- C:\Users\lectriweb\Documents\raber-react\node_modules\react-scripts\scripts\start.js
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:965:15)
at Function.Module._load (internal/modules/cjs/loader.js:841:27)
at Module.require (internal/modules/cjs/loader.js:1025:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object.<anonymous> (C:\Users\lectriweb\Documents\raber-react\node_modules\loader-utils\lib\interpolateName.js:4:20)
at Module._compile (internal/modules/cjs/loader.js:1137:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
at Module.load (internal/modules/cjs/loader.js:985:32)
at Function.Module._load (internal/modules/cjs/loader.js:878:14)
at Module.require (internal/modules/cjs/loader.js:1025:19) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'C:\\Users\\lectriweb\\Documents\\raber-react\\node_modules\\loader-utils\\lib\\interpolateName.js',
'C:\\Users\\lectriweb\\Documents\\raber-react\\node_modules\\loader-utils\\lib\\index.js',
'C:\\Users\\lectriweb\\Documents\\raber-react\\node_modules\\html-webpack-plugin\\index.js',
'C:\\Users\\lectriweb\\Documents\\raber-react\\node_modules\\react-scripts\\config\\webpack.config.js',
'C:\\Users\\lectriweb\\Documents\\raber-react\\node_modules\\react-scripts\\scripts\\start.js'
]
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! raber-react#0.1.0 start: `react-scripts start`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the raber-react#0.1.0 start 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\lectriweb\AppData\Roaming\npm-cache\_logs\2020-08-17T09_50_07_067Z-debug.log
Looks like Node can't find the module called 'emojis-list'.
Open your terminal, go inside your folder and try installing all the packages with:
npm install
If it doesn't work, try installing the emojis-list itself:
npm install emojis-list --save

Node.js npm install express - can't install express, error CERT_UNTRUSTED

I'm trying to install express on Raspberry Pi because I wanto to use it for REST API. The problem is that I get following message and any solution that I found on this site doesn't work.
npm http GET https://registry.npmjs.org/express
npm ERR! Error: SSL Error: CERT_UNTRUSTED
npm ERR! at ClientRequest.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/request/main.js:525:26)
npm ERR! at ClientRequest.g (events.js:192:14)
npm ERR! at ClientRequest.EventEmitter.emit (events.js:96:17)
npm ERR! at HTTPParser.parserOnIncomingClient [as onIncoming] (http.js:1582:7)
npm ERR! at HTTPParser.parserOnHeadersComplete [as onHeadersComplete] (http.js:111:23)
npm ERR! at CleartextStream.socketOnData [as ondata] (http.js:1485:20)
npm ERR! at CleartextStream.CryptoStream._push (tls.js:544:27)
npm ERR! at SecurePair.cycle (tls.js:898:20)
npm ERR! at EncryptedStream.CryptoStream.write (tls.js:285:13)
npm ERR! at Socket.ondata (stream.js:38:26)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 4.14.62-v7+
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "express" "--save"
npm ERR! cwd /usr/local/myapp
npm ERR! node -v v0.8.21
npm ERR! npm -v 1.2.11
npm ERR! code ESSL
npm ERR! Error: EACCES, open 'npm-debug.log'
npm ERR! { [Error: EACCES, open 'npm-debug.log'] errno: 3, code: 'EACCES', path: 'npm-debug.log' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
npm ERR! System Linux 4.14.62-v7+
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "express" "--save"
npm ERR! cwd /usr/local/myapp
npm ERR! node -v v0.8.21
npm ERR! npm -v 1.2.11
npm ERR! path npm-debug.log
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, open 'npm-debug.log'
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /usr/local/myapp/npm-debug.log
npm ERR! not ok code 0
Here are some commands that people asked about in other threads :
npm version
http_parser: '1.0',
node: '0.8.21',
v8: '3.11.10.25',
ares: '1.7.5-DEV',
uv: '0.8',
zlib: '1.2.3',
openssl: '1.0.0f',
npm: '1.2.11' }
npm list
pi#raspberrypi:/usr/local/myapp $ npm list
/usr/local/myapp
└── (empty)
I also tried to clear cache but nothing works and I'm stuck.
Thanks for help in advance.
Try this:
npm config set ca ""

Errors while installing expressjs on windows machine

I'm following this tutorial to install express JS. http://expressjs.com/2x/guide.html but I'm getting an error while installing the dependencies. Below is my error. Can somebody help me what I'm missing here?
C:\Users\myname\nodejs>npm install -d
npm info it worked if it ends with ok
npm info using npm#1.4.9
npm info using node#v0.10.28
npm ERR! install Couldn't read dependencies
npm ERR! package.json ENOENT, open 'C:\Users\myname\nodejs\package.json'
npm ERR! package.json This is most likely not a problem with npm itself.
npm ERR! package.json npm can't find a package.json file in your current directo
ry.
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\\Users\\myname\\nodejs\\\\node.exe" "C:\\Users\\sainath.
g\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-d"
npm ERR! cwd C:\Users\myname\nodejs
npm ERR! node -v v0.10.28
npm ERR! npm -v 1.4.9
npm ERR! path C:\Users\myname\nodejs\package.json
npm ERR! code ENOPACKAGEJSON
npm ERR! errno 34
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! C:\Users\myname\nodejs\npm-debug.log
npm ERR! not ok code 0
C:\Users\myname\nodejs>node app.js
module.js:340
throw err;
^
Error: Cannot find module 'C:\Users\myname\nodejs\app.js'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:906:3
You are a following a guide to express.js version 2.0 which is deprecated.
The latest express.js version is 4 and this is the guide you should actually follow :
express.js Getting Started Guide

Categories