webstorm react项目报错:Error: EPERM: operation not permitted

webstorm上导入了react项目,执行npm run start 之后就报错,

> cross-env APP_TYPE=site umi dev

fs.js:114
throw err;
^

Error: EPERM: operation not permitted, open ‘path\node_modules\.cache\@babel\register\.babel.7.2.2.development.json‘
at Object.openSync (fs.js:443:3)
at Object.writeFileSync (fs.js:1194:35)
at save (path\node_modules\@babel\register\lib\cache.js:52:15)
at process._tickCallback (internal/process/next_tick.js:61:11)
at Function.Module.runMain (internal/modules/cjs/loader.js:832:11)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:622:3)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `cross-env APP_TYPE=site umi dev`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! D:\Program Files\nodejs\node_cache\_logs\2019-06-14T07_34_39_651Z-debug.log

Process finished with exit code 1

看错误信息是要写某个文件时没有权限,这时根据路径过去看下是个隐藏文件,打开看一下只有一对“{}”,

网上能搜到的方法一般都是用管理员权限去运行“命令行”,这时候发现没用,

然后有的提到让修改整个项目文件夹的属性,给当前用户添加修改权限,也没用,

最后可以试下给这个.babel.7.2.2.development.json文件重命名一下,加个“_bak”后缀,然后再去webstorm中运行一下,

此时可以正常编译运行了,

原文地址:https://www.cnblogs.com/1394htw/p/11023629.html

时间: 2024-10-12 18:39:02

webstorm react项目报错:Error: EPERM: operation not permitted的相关文章

npm install 报错(npm ERR! errno -4048,Error: EPERM: operation not permitted,)解决方法

npm ERR! path E:\SouthernPowerGridProject\web_project\AutoOPS\autoops\node_modules\fsevents\node_modules\dashdash\node_modulesnpm ERR! code EPERMnpm ERR! errno -4048npm ERR! syscall scandirnpm ERR! Error: EPERM: operation not permitted, scandir 'E:\S

AndroidStudio导入Eclipse项目报错Error:Could not determine the class-path for interface com.android.builder.model.AndroidProject

AndroidStudio导入Eclipse项目报错 Error:Could not determine the class-path for interface com.android.builder.model.AndroidProject 错误原因: Gradle插件版本不一致导致,问题多出现在:eclipse项目转studio 解决步骤: https://blog.csdn.net/qq_21397217/article/details/65630730 原文地址:https://www

ng add ng-zorro-antd 安装时报错 已经是管理员还需要权限Error: EPERM: operation not permitted, lstat 'C:\ngWorkspace\qd\node_modules\fsevents\node_modules'

Error: EPERM: operation not permitted, lstat 'C:\ngWorkspace\qd\node_modules\fsevents\node_modules' ng add ng-zorro-antd -f fsevents 这个依赖安装不上 可以使用 -f 指令 强制安装 ng add ng-zorro-antd 安装时报错 已经是管理员还需要权限Error: EPERM: operation not permitted, lstat 'C:\ngWor

nhandled rejection Error: EPERM: operation not permitted, open 'C:\Program Files\nodejs\node_cache npm ERR! cb() never called!

安装全局包时报错,之前已经遇到过,结果第二次又忘记解决方法,果然还是要记下来,好记性不如烂笔头哇 $ npm i electron -gUnhandled rejection Error: EPERM: operation not permitted, open 'C:\Program Files\nodejs\node_cache\_cacache\tmp\f23044b6'npm ERR! cb() never called! npm ERR! This is an error with n

"npm ERR! Error: EPERM: operation not permitted"问题解决

在基于macaca进行自动化测试的时候,遇到如下问题: E:\AutoTest\Macaca\LocalTEST\macaca-test-sample\macaca-test>macaca doctor   Node.js checklist:   node env: C:\Program Files\nodejs\node.exe  node version: v6.3.0   Android checklist:   JAVA version is `1.8.0_91`  JAVA_HOME

ERROR EPERM: operation not permitted, mkdir 'C:\Users\Administrator\Desktop\text\nuxt\basic\.nuxt\components'

C:\Users\Administrator\Desktop\text\nuxt>cd basic C:\Users\Administrator\Desktop\text\nuxt\basic>npm run dev > [email protected] dev C:\Users\Administrator\Desktop\text\nuxt\basic > nuxt i Preparing project for development 10:04:25 i Initial b

ionic start 创建ionic项目报错,及解决过程

问题描述: 前一次创建利用命令行创建ionic项目一次性成功,第二次没有运行: $ npm install -g ionic cordova 直接运行: ionic start ionicDemo 出现上图错误: × Running command - failed!Exception: npm ERR! path C:\work\ionicdemo\node_modules\fsevents\node_modulesnpm ERR! code EPERMnpm ERR! errno -4048

cocoapods 安装报错 ERROR: While executing gem ... (Errno::EPERM) Operation not permitted - /usr/bin/xcodeproj

cocoapods 安装报错 ERROR:  While executing gem ... (Errno::EPERM)     Operation not permitted - /usr/bin/xcodeproj 执行下面语句安装即可: sudo gem install -n /usr/local/bin cocoapods

【转】eclipse新建项目,报错“Error: workspace\appcompat_v7\res\values-v21\styles_base.xml No resource found that matches the given name”

原文网址:http://www.cnblogs.com/mbp-study/p/5268478.html 新建项目报错,不知道为什么,以前从未出现过的错误,把sdk更新之后,出现莫名错误,自己也是一知半解,在网上找了好久的错误,终于在一个english网站找到了解决方法,soga,从未觉得english如此美好 错误信息如下 ....\appcompat_v7\res\values-v21\styles_base.xml:75: error: Error retrieving parent fo