- 操作系统:Windows 10。
- npm 版本:6.9.0
- 节点版本:12.4.0
我正在开发一个博览会应用程序。
我想在我的 expo 应用程序上安装所有软件包(npm install)。但是,发生了错误:
17254 error [OperationalError: EPERM: operation not permitted, unlink ...
我在很多主题上都看到过这个错误,但没有人回答我的问题。
我已经尝试过:
- 以管理员身份启动我的终端。
- npm 配置设置 safe-perm=true。
- npm install --no-bin-links
- npm 缓存清除 --force
我的错误消息示例:
17254 error cause: [Error: EPERM: operation not permitted, unlink 'C:\Users\Thomas\Desktop\someDirectory\someDirectory\someDirectory\someDirectory\node_modules\.staging\react-native-99ed309f\Libraries\Renderer\oss\ReactFabric-dev.js'] {
17254 error errno: -4048,
17254 error code: 'EPERM',
17254 error syscall: 'unlink',
17254 error path: 'C:\\Users\\Thomas\\Desktop\\someDirectory\\someDirectory\\someDirectory\\someDirectory\\node_modules\\.staging\\react-native-99ed309f\\Libraries\\Renderer\\oss\\ReactFabric-dev.js'
17254 error },
17254 error stack: 'Error: EPERM: operation not permitted, unlink ' +
17254 error "'C:\\Users\\Thomas\\Desktop\\someDirectory\\someDirectory\\someDirectory\\someDirectory\\node_modules\\.staging\\react-native-99ed309f\\Libraries\\Renderer\\oss\\ReactFabric-dev.js'",
17254 error errno: -4048,
17254 error code: 'EPERM',
17254 error syscall: 'unlink',
17254 error path: 'C:\\Users\\Thomas\\Desktop\\someDirectory\\someDirectory\\someDirectory\\someDirectory\\node_modules\\.staging\\react-native-99ed309f\\Libraries\\Renderer\\oss\\ReactFabric-dev.js'
17254 error }
17255 error The operation was rejected by your operating system.
17255 error It's possible that the file was already in use (by a text editor or antivirus),
17255 error or that you lack permissions to access it.
17255 error
17255 error If you believe this might be a permissions issue, please double-check the
17255 error permissions of the file and its containing directories, or try running
17255 error the command again as root/Administrator (though this is not recommended).
17256 verbose exit [ -4048, true ] ```
是否有另一个正在运行的节点实例,也使用 ReactFabric-dev.js?如果是这样,请终止并重试。还可以尝试将项目移动到距离根目录“更近”的文件夹中。 Windows 有时会对很长的路径感到困惑。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)