npm-材质设计图标的压缩文件数据似乎已损坏 [英] npm - tarball data for material-design-icons seems to be corrupted

查看:232
本文介绍了npm-材质设计图标的压缩文件数据似乎已损坏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在运行npm install material-design-icons@3.0.1时遇到此错误:

I'm having this error while running a npm install material-design-icons@3.0.1:

tarball data for material-design-icons@3.0.1 (sha1-mnHEh0chjrylHlGmbaaCA4zct78=) seems to be corrupted
npm ERR! path D:\speech-analytics\node_modules\.staging\material-design-icons-7d5a1f73\action\drawable-xxhdpi\ic_assignment_ind_white_48dp.png
npm ERR! code EPERM
npm ERR! errno -4048
npm ERR! syscall unlink
npm ERR! Error: EPERM: operation not permitted, unlink 'D:\\speech-analytics\node_modules\.staging\material-design-icons-7d5a1f73\action\drawable-xxhdpi\ic_assignment_ind_white_48dp.png'
npm ERR!  { Error: EPERM: operation not permitted, unlink 'D:\\speech-analytics\node_modules\.staging\material-design-icons-7d5a1f73\action\drawable-xxhdpi\ic_assignment_ind_white_48dp.png'

在这里被记录为错误,但仍然没有答案也没有解决办法.

Here it's documented as a bug, but still without an answer nor a fix.

我尝试重新安装节点,升级到最新的npm版本(当前正在运行6.4.1),做了cache clean --force,尝试了npm install --no-optional,删除了package-lock.json,删除了npm& AppData目录中的npm-cache文件夹,以管理员身份运行所有内容,但仍然没有运气.

I've tried to reinstall node, upgraded to latest npm version (currently running 6.4.1), did a cache clean --force, tried a npm install --no-optional, removed package-lock.json, removed npm & npm-cache folders from AppData directory, running everything as Administrator, but still no luck.

我什至尝试了material-design-icons@3.0.0,但错误仍然存​​在.

I even tried with material-design-icons@3.0.0 but the error remains.

如果我导航到日志(node_modules\.staging\material-design-icons-7d5a1f73\action\drawable-xxhdpi)中显示的文件夹,则该文件夹为空,并且是整个node_modules目录中唯一的文件夹.我可以毫无问题地删除该目录,因此它似乎不是权限/锁定问题.

If I navigate to the folder that appears in the log (node_modules\.staging\material-design-icons-7d5a1f73\action\drawable-xxhdpi), it's empty, and is the only folder that exists in the entire node_modules directory. I can delete that dir without any problems, so it does not seem to be a permissions/lock issue.

有什么建议吗?

推荐答案

最后,我通过以下方法解决了此问题:

Finally, I got this fixed by:

  • 删除node_modules文件夹
  • 运行npm update
  • 运行npm install
  • Removing node_modules folder
  • Running npm update
  • Running npm install

据我了解, npm更新应该已经更新了package.json文件,但是所有依赖项都保持与以前相同的版本.

As far I understand, the npm update should have updated the package.json file, but all dependencies kept the same versions as we had it before.

这篇关于npm-材质设计图标的压缩文件数据似乎已损坏的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆