npm install returns errors - node.js

when I run npm install I get the following errors.
npm WARN enoent ENOENT, open '/Users/IBricchi/package.json'
npm WARN generator-steroids#1.0.21 requires a peer of yo#1.8.1 || >=1.8.3 but none was installed.
npm WARN grunt-contrib-clean#1.0.0 requires a peer of grunt#>= 0.4.5 but none was installed.
npm WARN grunt-contrib-coffee#1.0.0 requires a peer of grunt#>= 0.4.5 but none was installed.
npm WARN grunt-contrib-concat#1.0.1 requires a peer of grunt#>=0.4.0 but none was installed.
npm WARN grunt-contrib-sass#1.0.0 requires a peer of grunt#>=0.4.0 but none was installed.
npm WARN grunt-extend-config#0.9.5 requires a peer of grunt#>=0.4.0 but none was installed.
npm WARN IBricchi No description
npm WARN IBricchi No repository field.
npm WARN IBricchi No README data
npm WARN IBricchi No license field.
I've tried looking for answers online, but everything I've tried has done nothing. Any help would be appreciated.

Looks like package.json was not found by npm in /Users/IBricchi/package.json. Probably you are running npm install from your home directory by mistake. You should run npm install from your project root directory.

Related

TS6053 Building Swashbuckle.AspNetCore

I cloned Swashbuckle.AspNetCore and am trying to build it
However the node_modules folder is missing
I ran npm i redoc and got the following output
npm WARN saveError ENOENT: no such file or directory, open 'C:\Windows\System32\package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open 'C:\Windows\System32\package.json'
npm WARN redoc#2.0.0-rc.40 requires a peer of mobx#^4.2.0 || ^5.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN redoc#2.0.0-rc.40 requires a peer of react#^16.8.4 but none is installed. You must install peer dependencies yourself.
npm WARN redoc#2.0.0-rc.40 requires a peer of react-dom#^16.8.4 but none is installed. You must install peer dependencies yourself.
npm WARN redoc#2.0.0-rc.40 requires a peer of styled-components#^4.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN mobx-react#6.3.0 requires a peer of mobx#^5.15.4 || ^4.15.4 but none is installed. You must install peer dependencies yourself.
npm WARN mobx-react#6.3.0 requires a peer of react#^16.8.0 || 16.9.0-alpha.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-tabs#3.1.1 requires a peer of react#^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN #redocly/react-dropdown-aria#2.0.11 requires a peer of react#^16.8.0 but none is installed. You must install peer dependencies yourself.
npm WARN #redocly/react-dropdown-aria#2.0.11 requires a peer of react-dom#^16.8.0 but none is installed. You must install peer dependencies yourself.
npm WARN #redocly/react-dropdown-aria#2.0.11 requires a peer of styled-components#^5.1.1 but none is installed. You must install peer dependencies yourself.
npm WARN mobx-react-lite#2.2.1 requires a peer of mobx#^4.0.0 || ^5.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN mobx-react-lite#2.2.1 requires a peer of react#^16.8.0 but none is installed. You must install peer dependencies yourself.
npm WARN System32 No description
npm WARN System32 No repository field.
npm WARN System32 No README data
npm WARN System32 No license field.
How should I proceed?
I needed to be in the Swashbuckle.AspNetCore.ReDoc folder before running the command
npm i redoc

unable to start node project

D:\freelancing\FlowerAppProject\WEBAPP_10_5>npm install
npm WARN deprecated fsevents#1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
> node#11.15.0 preinstall D:\freelancing\FlowerAppProject\WEBAPP_10_5\node_modules\node
> node installArchSpecificPackage
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#^1.2.2 (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 #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/animations#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/cdk#^8.2.3 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/common#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/core#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/forms#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/material#^8.2.3 but none is installed. You must install peer dependencies yourself.
npm WARN #angular/compiler-cli#7.2.16 requires a peer of typescript#>=3.1.1 <3.3 but none is installed. You must install peer dependencies yourself.
npm WARN #ngtools/webpack#7.3.10 requires a peer of typescript#>=2.4.0 < 3.3 but none is installed. You must install peer dependencies yourself.
npm WARN #pscoped/ngx-pub-sub#3.0.0 requires a peer of #angular/common#^8.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN #pscoped/ngx-pub-sub#3.0.0 requires a peer of #angular/core#^8.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN angular-image-slider#0.0.9 requires a peer of #angular/animations#^8.2.13 but none is installed. You must install peer dependencies yourself.
npm WARN ng-image-slider#2.5.0 requires a peer of #angular/common#^8.2.2 but none is installed. You must install peer dependencies yourself.
npm WARN ng-image-slider#2.5.0 requires a peer of #angular/core#^8.2.2 but none is installed. You must install peer dependencies yourself.
npm ERR! file bash
npm ERR! path bash
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn bash
npm ERR! node#11.15.0 preinstall: `node installArchSpecificPackage`
npm ERR! spawn bash ENOENT
npm ERR!
npm ERR! Failed at the node#11.15.0 preinstall 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\hunter\AppData\Roaming\npm-cache\_logs\2020-05-15T13_23_06_391Z-debug.log
First - have you run npm install -g angular already?
If so -
Have you tried to manually install the missing dependencies?
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/animations#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/cdk#^8.2.3 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/common#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/core#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/forms#^8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN #angular-material-extensions/password-strength#4.1.2 requires a peer of #angular/material#^8.2.3 but none is installed. You must install peer dependencies yourself.
npm WARN #angular/compiler-cli#7.2.16 requires a peer of typescript#>=3.1.1 <3.3 but none is installed. You must install peer dependencies yourself.
npm WARN #ngtools/webpack#7.3.10 requires a peer of typescript#>=2.4.0 < 3.3 but none is installed. You must install peer dependencies yourself.
npm WARN #pscoped/ngx-pub-sub#3.0.0 requires a peer of #angular/common#^8.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN #pscoped/ngx-pub-sub#3.0.0 requires a peer of #angular/core#^8.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN angular-image-slider#0.0.9 requires a peer of #angular/animations#^8.2.13 but none is installed. You must install peer dependencies yourself.
npm WARN ng-image-slider#2.5.0 requires a peer of #angular/common#^8.2.2 but none is installed. You must install peer dependencies yourself.
npm WARN ng-image-slider#2.5.0 requires a peer of #angular/core#^8.2.2 but none is installed. You must install peer dependencies yourself.
The package.json file should take care of this in theory, but obviously it is not.
You should go down the list and manually npm install #angular/animations#^8.2.14 etc until all the entries are installed successfully and try again.
For some reason on your machine it's not automatically picking up the dependencies - I assume that you installed angular already or this whole project is coming from some tutorial you're following?
These lines mean that it tries to run bash command but can not find it:
npm ERR! file bash
npm ERR! path bash
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn bash
npm ERR! node#11.15.0 preinstall: `node installArchSpecificPackage`
npm ERR! spawn bash ENOENT
I assume that you are running it under the Windows OS, where bash is absent (if you are not running it under WSL e.g.).

npm WARN package.json for latest version

We are already using the latest version of angular ("#angular/core": "~8.2.5").
But when install, npm gives some warning about the module versions.
Please see the above console result :
npm WARN angular-pell#0.1.0 requires peer of #angular/common#^5.2.5 but none is installed. You must install peer dependencies yourself.
npm WARN angular-pell#0.1.0 reuqires peer of #angular/core#^5.2.5 but none is installed. You must install peer dependencies yourself.
npm WARN #angular/core#2.4.10 requires peer of rxjs#^5.0.1 but none is installed. You must install peer dependencies yourself.
What is about the npm warn?
Why npm provides some warns?
Try runing npm audit:
npm audit fix

Sodium fails to install when on Raspberry Pi

When trying to install Sodium with NPM on my Raspberry Pi, the installation always fails and complains that it does not have write access to /home/Captain/node_modules/libsodium. I'm running the installation command through sudo, and the install still doesn't want to work. Did I just royally mess up my install?
$ sudo npm install sodium
npm WARN checkPermissions Missing write access to /home/Captain/node_modules/libsodium
npm WARN enoent ENOENT: no such file or directory, open '/home/Captain/package.json'
npm WARN discord.js#11.2.1 requires a peer of erlpack#hammerandchisel/erlpack but none is installed. You must install peer dependencies yourself.
npm WARN discord.js#11.2.1 requires a peer of node-opus#^0.2.6 but none is installed. You must install peer dependencies yourself.
npm WARN discord.js#11.2.1 requires a peer of opusscript#^0.0.3 but none is installed. You must install peer dependencies yourself.
npm WARN discord.js#11.2.1 requires a peer of libsodium-wrappers#^0.5.4 but none is installed. You must install peer dependencies yourself.
npm WARN discord.js#11.2.1 requires a peer of uws#^0.14.5 but none is installed. You must install peer dependencies yourself.
npm WARN Captain No description
npm WARN Captain No repository field.
npm WARN Captain No README data
npm WARN Captain No license field.
npm ERR! path /home/Captain/node_modules/libsodium
npm ERR! code ELOOP
npm ERR! errno -40
npm ERR! syscall access
npm ERR! ELOOP: too many symbolic links encountered, access '/home/Captain/node_modules/libsodium'
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2017-11-21T02_23_41_242Z-debug.log
no, your setup is fine.
try this command
sudo chmod 777 /home/Captain/node_modules/libsodium
that should fix it.
EDIT: I know this is a 2 year old answer but I would like to tell people who stumble across this post to NEVER use 777! 777 allows anyone to read, write and execute your file, you SHOULD use 644 which allows anyone to read the file only while you can read and write said file.

npm install ts-md5 ERROR

I'm getting an error everytime I execute npm install ts-md5 command in node.js command prompt. I have no idea hoe to resolve this problem. Hope you can help me, thanks in advance Here is the error:
C:\Users\Administrator>npm install ts-md5
C:\Users\Administrator
+-- UNMET PEER DEPENDENCY #angular/core#*
+-- UNMET PEER DEPENDENCY #ionic-native/core#^3.6.0 || >=4.0.0
+-- UNMET PEER DEPENDENCY rxjs#^5.0.1
`-- ts-md5#1.2.2
npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\Administrator\
package.json'
npm WARN #ionic-native/network#4.1.0 requires a peer of #ionic-native/core#^3.6.
0 || >=4.0.0 but none was installed.
npm WARN #ionic-native/network#4.1.0 requires a peer of #angular/core#* but none
was installed.
npm WARN #ionic-native/network#4.1.0 requires a peer of rxjs#^5.0.1 but none was
installed.
npm WARN Administrator No description
npm WARN Administrator No repository field.
npm WARN Administrator No README data
npm WARN Administrator No license field.
It seems that package.json is missing.
You can use : npm install only inside npm project.
Create a new folder and execute npm init on it and follow the instructions.

Resources