error while installing soap module using npm - node.js

Hi i am getting the error below while trying to install soap module using npm.
Below is the error
npm WARN node-expat#2.0.0 package.json: bugs['name'] should probably be bugs['url']
Any help how to proceed further will be much helpful

As already stated in the message from NPM, that's not a error. It's a warning, that tells you the package you're trying to install has wrong data in the bugs field, which is only one of the various fields available in the package.json file.
An related question: npm WARN package.json: No repository field

Related

I am getting an error while creating a react app [duplicate]

Whenever I try to run npx create-react-app my-app, it shows the error:
npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/#types/eslint/-/eslint-8.4.4.tgz - Not found
npm ERR! 404
npm ERR! 404 '#types/eslint#http://registry.npmjs.org/#types/eslint/-/eslint-8.4.4.tgz' is not in this registry.
When I try like eslint-8.4.0.tgz I can download it but 8.4.4 just doesn't exist.
There is an issue with v.8.4.4 on the NPM
Change your package.json and use 8.4.3 instead!
Pin it in "resolutions" for yarn
"resolutions": {
"#types/eslint": "8.4.3"
}
or "overrides" for npm
"overrides": {
"#types/eslint": "8.4.3"
}
more info about overriding values in NPM:
How do I override nested NPM dependency versions?
more about issue (check it here):
It is not a problem of React, but a problem of a package #types/eslint. Seems like the bad version of the package was upgraded and it's not downloadable.
To solve the issue, you may want to create a react app, without using create-react-app. To do this, try to use the following tutorial
Or you can wait until the package is fixed.

Every time I try creating react app it failsand get error 404 not found GET https://registry.npmjs.org [duplicate]

Whenever I try to run npx create-react-app my-app, it shows the error:
npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/#types/eslint/-/eslint-8.4.4.tgz - Not found
npm ERR! 404
npm ERR! 404 '#types/eslint#http://registry.npmjs.org/#types/eslint/-/eslint-8.4.4.tgz' is not in this registry.
When I try like eslint-8.4.0.tgz I can download it but 8.4.4 just doesn't exist.
There is an issue with v.8.4.4 on the NPM
Change your package.json and use 8.4.3 instead!
Pin it in "resolutions" for yarn
"resolutions": {
"#types/eslint": "8.4.3"
}
or "overrides" for npm
"overrides": {
"#types/eslint": "8.4.3"
}
more info about overriding values in NPM:
How do I override nested NPM dependency versions?
more about issue (check it here):
It is not a problem of React, but a problem of a package #types/eslint. Seems like the bad version of the package was upgraded and it's not downloadable.
To solve the issue, you may want to create a react app, without using create-react-app. To do this, try to use the following tutorial
Or you can wait until the package is fixed.

Unable to create a new angular project

I am new to Angular and I am facing the following problem in creating a new project. I have already installed nodejs and npm which are the prerequisites of Angular. I also installed the angular CLI but when I am trying to create a new project the following error is coming.
[⠼ Installing packages...npm WARN deprecated request#2.88.2: request has been deprecated, see
npm WARN deprecated urix#0.1.0: Please see
npm WARN deprecated resolve-url#0.2.1
npm ERR! Unexpected end of JSON input while parsing near '...p":"^0.8.0","grunt-co'
npm ERR! A complete log of this run can be found in:
npm ERR! /home/saumya/.npm/_logs/2020-04-12T15_22_00_125Z-debug.log
✖ Package install failed, see above.
The Schematic workflow failed. See above.
You need to clear npm cache. If u are using windows location is C:\Users\\AppData\Roaming\npm-cache. Simply delete cache folder and try again
If this also not work, it's better to install the latest npm and angular by removing the old version and npm-cache as well. Then you will have the latest compatible versions
remove this folder: C:\Users\AppData\Roaming\npm-cache.
OR
Run this command:
npm cache clear --force

Why am I getting Unexpected token '\u0000' when using npm install -g package

This is probably a Windows specific issue but I haven't found any information when googling this issue. I had been using ionic framework which relies on Cordova (or Phonegap). However, the problem is not specific to any of these packages. I see this error quite often. So, the error is when I run a command such as the following:
npm install -g cordova
However, I could substitute various other packages and get the same error. I'll paste the snippet (very brief) below of the error message. What is strange is that I had an ionic project working in that directory earlier. Then today it told me that ionic could not be found. My hunch is that this is a different issue than the main issue I am describing here.
I installed git bash so I do have a linux-like environment that I could try. I would just select Git Bash for a bash window with various bash commands. If there is an easier way to fix this for Windows users, please let me know. I have seen courses on Pluralsight where the instructors seem to be happily using npm with no problems. Also, when I use yeoman, I also at some point, in many cases, get the same error.
The error is
npm ERR! Failed to parse json
npm Unexpected token '\u0000' at 1:1
npm ERR!
npm ERR! ^
npm ERR! File: c:\Users\Bruce\AppData\Roaming\npm-cache\amdefine\1.0.0\package\package.json
npm ERR! Failed to parse package.json data.
npm ERR! package.json must be actual JSON, not just JavaScript.
npm ERR!
npm ERR! This is not a bug in npm
npm ERR! Tell the package author to fix their package.json file. JSON.parse.
Thanks in advance for any help/advice,
Bruce
Via this question on SO it could be that you just have to do:
npm cache clean.
But, also try the other methods suggested there like adding the registry option:
npm install <packagename> --registry http://registry.npmjs.org/.
Or, if you've been mingling with the package.json file by yourself, check if it's valid.

What does 'invalid' mean when using npm list?

I am new to nodejs and i had just installed bower module globally. Ever since then, npm list command gives the following output which I searched for on the web but couldn't find any help :
**npm ERR! invalid: chalk#0.5.1 /usr/local/lib/node_modules/bower/node_modules/chalk
npm ERR! invalid: ansi-regex#0.2.1 /usr/local/lib/node_modules/bower/node_modules/chalk/node_modules/has-ansi/node_modules/ansi-regex
npm ERR! invalid: configstore#0.3.1 /usr/local/lib/node_modules/bower/node_modules/update-notifier/node_modules/configstore
npm ERR! invalid: object-assign#0.3.1 /usr/local/lib/node_modules/bower/node_modules/update-notifier/node_modules/latest-version/node_modules/package-json/node_modules/got/node_modules/object-assign
npm ERR! invalid: registry-url#0.1.1 /usr/local/lib/node_modules/bower/node_modules/update-notifier/node_modules/latest-version/node_modules/package-json/node_modules/registry-url
npm ERR! invalid: strip-ansi#0.2.2 /usr/local/lib/node_modules/bower/node_modules/update-notifier/node_modules/string-length/node_modules/strip-ansi
npm ERR! not ok code 0**
The rest of the output is normal and lists the installed modules. Can anyone explain what's going on?
I was getting this error having the same package installed both in "dependencies" and "devDependencies" with different versions.
It means that something depends on, for example, "async":"0.9.3" but when they do require("async"), npm thinks that they'll get some other version. And also check that the dependencies and their versions listed in your package.json file are available.
If everything is right then you can solve this problem with
npm update
followed by
npm install.
I was getting this error after installing a newer version of a module, without updating my package.json. So the package.json required the older version, while npm list was detecting a newer version in my node_modules directory.
Running the following command got me rid of the message.
npm install {required_module}#{new_version} --save
Simplest answer
This can arise when the installed version of a package does not correspond to what package.json would install.
Example
Say you have specified "axios": "0.19.2", in your package.json, but after that you would install a specific version using npm install axios#0.18.1.
An npm list | grep axios would now yield
├─┬ axios#0.18.1 invalid
Follow the instructions in this answer on how to fix it.
I was getting a related but different error (but ended up here, so I'm answering here) where after running npm update I'd get. (No such issue with npm install, fwiw)
myapp#1.0.0 /home/malcolm/myapp
├── beeminder#1.4.3 invalid
The beeminder package is one I maintain, so in my main app I had set its semver to latest. This seemed to work fine before, but I guess a newer version of npm doesn't like it.
I figured it was reasonable to just use ^1.4.3 because if I'm introducing new changes then I probably am changing my own code anyway. But if for some weird reason you need the latest latest of a package (including breaking changes!) then you can use >= as a prefix instead of ^.

Resources