When I run `npm install`, it returns with `ERR! code EINTEGRITY` (npm 5.3.0)

后端 未结 27 1472
闹比i
闹比i 2020-11-28 02:29

I am getting this error while running sudo npm install. On my server, npm was installed earlier. I\'ve tried to delete the package-lock.json file,

相关标签:
27条回答
  • 2020-11-28 02:49

    Updating the .npmrc files' entries for scoped and un-scoped packages worked for me. So I ended up using the

    npm config set @scope_name:registry SCOPED_REGISTRY_URL

    and

    npm config set registry PUBLIC_REGISTRY_URL

    0 讨论(0)
  • 2020-11-28 02:49

    Try this

      Step-1) Delete package-lock.json from root folder.
      Step-2) Delete node_modules folder
      Step-3) run npm install command in root
    
    0 讨论(0)
  • 2020-11-28 02:54

    My problem was 2 things:

    1. Bad package-lock.json file
    2. The existance of npm-shrinkwrap.json together with the package-lock.json file

    What i did is:

    1. Deleted the package-lock.json file
    2. Delete the npm-shrinkwrap.json file
    3. Ran npm install again (which recreated a good package-lock file)

    Fixed my error!

    0 讨论(0)
提交回复
热议问题