issue using npm to install upper-case module on linuxmint OS - node.js

npm WARN saveError ENOENT: no such file or directory, open '/home/spipl8/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/home/spipl8/package.json'
npm WARN spipl8 No description
npm WARN spipl8 No repository field.
npm WARN spipl8 No README data
npm WARN spipl8 No license field.
this all error was occur when i try to install the upper-case modules of node.js NPM on linux mint please help me out to solve it.

I guess this is not the issue with npm, the error is saying it cannot find package.json in your directory.

Related

npm install not working: "npm ERR! code ERR_SSL_WRONG_VERSION_NUMBER"

I can't install modules for my react app, when i run npm i it does this:
npm WARN read-shrinkwrap This version of npm is compatible with lockfileVersion#1, but package-lock.json was generated for lockfileVersion#2. I'll try to do my best with it!
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\setprototypeof-b857a2ac\package.json'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\setprototypeof-b857a2ac\index.d.ts'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\setprototypeof-b857a2ac\index.js'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\setprototypeof-b857a2ac\LICENSE'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\rc-5aecd98b\test\ini.js'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\setprototypeof-b857a2ac\README.md'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\rc-5aecd98b\test\nested-env-vars.js'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\rc-5aecd98b\test\test.js'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\term-size-f230f088\vendor\windows\term-size.exe'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\ast-types-5383d6cc\def\type-annotations.js'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\marco\Code\backend\node_modules\.staging\ast-types-5383d6cc\def\typescript.js'
npm WARN backend#1.0.0 No description
npm WARN backend#1.0.0 No repository field.
npm ERR! code ERR_SSL_WRONG_VERSION_NUMBER
npm ERR! errno ERR_SSL_WRONG_VERSION_NUMBER
npm ERR! request to https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz failed, reason: 4376:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:c:\ws\deps\openssl\openssl\ssl\record\ssl3_record.c:308:
npm ERR!
I tried reinstalling npm and it does the same thing. I tried with another project and I'm getting the same error. I found another question where someone had the same problem but noone replied. I even tried to set the npm registry to http://registry.npmjs.org instead of https://registry.npmjs.org, and setting the strict-ssl option to false, but it still won't work.
My npm version is 6.14.13 and my node version is v14.17.1.
Any help?
P.S.: I'm not using a proxy
Quick solution would be to delete node_modules and package-lock.json, so that when you reinstall the packages, they get installed with the lockfileVersion#1 instead of lockfileVersion#2.
I wouldn't suggest that solution though, as if you work in a team you would be forcing the others to do the same in order to fix it.
The problem is the npm version v6.x.x supports lockfileVersion#1 while v7.x.x supports lockfileVersion#2.
So a better solution would be to simply update your npm version to a v7 and higher.
Here you can find an interesting related discussion about it: Is there any way to fix package-lock.json lockfileVersion so npm uses a specific format?

unable to upgrade node js latest version

I'm trying to upgrade the node latest version not working but npm is upgraded to latest version and I don't have admin access.
I'm getting following error, When use this comment npm install node#latest
npm WARN saveError ENOENT: no such file or directory, open 'C:\Users\Des
ktop\foldername\package.json'
npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\Deskto
p\react\package.json'
npm WARN react No description
npm WARN react No repository field.
npm WARN react No README data
npm WARN react No license field.
Try adding -g flag to your command to specify that it is a global install.

Installation error while using npm install react-native-gifted-messenger --save

I am using Ubuntu 16.04 LTS, node version 6, and npm version 5
Getting the following error while installing
npm WARN saveError ENOENT: no such file or directory, open '/home/p/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/home/p/package.json'
npm WARN p No description
npm WARN p No repository field.
npm WARN p No README data
npm WARN p No license field.
Any suggestions how to resolve it would be appreciated.

No such file package.json when running npm i

When I run the following commands:
npm i && npm run
I get the following error:
npm WARN saveError ENOENT: no such file or directory, open '/Users/Singh/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/Users/Singh/package.json'
npm WARN Singh No description
npm WARN Singh No repository field.
npm WARN Singh No README data
npm WARN Singh No license field.
Why am I getting this error and how do I fix it?
First check there is package.json file or not if not create package.json file using npm init
The problem is that you're in the wrong directory -- you're in your user directory. If you cloned something from a repository, make sure you navigate to that directory before running npm i:
cd path/to/cloned/project
npm i && npm run <script_here>

facing issues whille installing npm ts loader and npm css loader

I am getting all these warning while installing ts loader and css loader..
npm ts loader
user#user-ThinkPad-T420s:~$ npm install --save-dev ts-loader
npm WARN saveError ENOENT: no such file or directory, open '/home/user/package.json'
/home/user
`-- ts-loader#2.1.0
npm WARN enoent ENOENT: no such file or directory, open '/home/user/package.json'
npm WARN user No description
npm WARN user No repository field.
npm WARN user No README data
npm WARN user No license field.
npm css loader
user#user-ThinkPad-T420s:~$ npm install --save-dev css-loader
npm WARN saveError ENOENT: no such file or directory, open '/home/user/package.json'
/home/user
`-- css-loader#0.28.2
npm WARN enoent ENOENT: no such file or directory, open '/home/user/package.json'
npm WARN user No description
npm WARN user No repository field.
npm WARN user No README data
npm WARN user No license field.
can anyone tell me how i can fix this ?
This is happening because you pass --save-dev parameter to npm when you install ts-loader and css-loader modules in a directory with no package.json in it.
If this is a new project, I suggest you to start by npm init, as it will create you a fresh package.json file for your project.
You can always install dependency globally if you needed it for more than one project:
npm install -g ts-loader css-loader
Others alert are not very important, but you can add a licence and a README file to get rid of it if you care.

Resources