简体   繁体   English

我如何解决赛普拉斯中 index.js 的插件错误

[英]how do i solve plugin error for index.js in cypress

I am getting following error for Cypress我收到赛普拉斯的以下错误

The following error was thrown by a plugin.插件引发了以下错误。 We stopped running your tests because a plugin crashed.由于插件崩溃,我们停止运行您的测试。 Please check your plugins file (/home/dev2/Desktop/kavitaSeffcon/CypressProject/cypress/plugins/index.js)请检查您的插件文件(/home/dev2/Desktop/kavitaSeffcon/CypressProject/cypress/plugins/index.js)

Error: ENOENT: no such file or directory, stat '/initrd.img'错误:ENOENT:没有这样的文件或目录,stat '/initrd.img'

can please suggest exact solution for this error可以请为此错误建议确切的解决方案

I have installed Cypress 9.1.0 and faced the same issue today.我已经安装了 Cypress 9.1.0,今天遇到了同样的问题。 Can you please specify what is your Cypress version?你能指定你的赛普拉斯版本是什么吗?

Alright so during the troubleshoot our goal would be to reach the nearest version of node required as we can see in below error logs.好的,所以在故障排除期间,我们的目标是达到所需的最近节点版本,正如我们在下面的错误日志中看到的那样。

-bash-3.2$ npm updatenpm WARN old lockfilenpm WARN old lockfile The package-lock.json file was created with an old version of npm,npm WARN old lockfile so supplemental metadata must be fetched from the registry.npm WARN old lockfilenpm WARN old lockfile This is a one-time fix-up, please be patient...npm WARN old lockfilenpm WARN EBADENGINE Unsupported engine {npm WARN EBADENGINE package: undefined,npm WARN EBADENGINE required: { node: '14.17.0' },npm WARN EBADENGINE current: { node: 'v17.2.0', npm: '8.1.0' }npm WARN EBADENGINE } -bash-3.2$ npm updatenpm WARN old lockfilenpm WARN old lockfile The package-lock.json file was created with an old version of npm,npm WARN old lockfile so supplemental metadata must be fetched from the registry.npm WARN old lockfilenpm WARN old lockfile This is a one-time fix-up, please be patient...npm WARN old lockfilenpm WARN EBADENGINE Unsupported engine {npm WARN EBADENGINE package: undefined,npm WARN EBADENGINE required: { node: '14.17.0' },npm WARN EBADENGINE当前:{节点:'v17.2.0',npm:'8.1.0'}npm WARN EBADENGINE}

added 7 packages, removed 6 packages, changed 57 packages, and audited 350 packages in 11s 11s新增7个包,删除6个包,改57个包,审核350个包

64 packages are looking for fundingrun npm fund for details 64包正在寻找资金运行npm基金详情

added 7 packages, removed 6 packages, changed 57 packages, and audited 350 packages in 11s 11s新增7个包,删除6个包,改57个包,审核350个包

64 packages are looking for funding 64个包正在寻找资金

run npm fund for details运行npm fund了解详情

As we currently have 17.2.0 and the required is 14.17.0.因为我们目前有 17.2.0,需要的是 14.17.0。 To fix this要解决这个问题

npm cache clearnpm cache clean --forcenpm install -g cypresssudo n 14.17.0rm -rf put your existing version . npm cache clearnpm cache clean --forcenpm install -g cypresssudo n 14.17.0rm -rf把你现有的版本 {Perform this in the folder where your previous version of node was installed} {在安装了以前版本节点的文件夹中执行此操作}

Open a new terminal打开一个新的终端

node -v npm installnpx cypress open node -v npm installnpx cypress open

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何将多个插件添加到 cypress/plugins/index.js 文件? - How do your add multiple plugins to cypress/plugins/index.js file? 如何在 React index.js 中编写脚本? - How do I write script in React index.js? 我该如何解决 index.js:1 错误:网络错误 *at createError (createError.js:16) *at XMLHttpRequest.handleError (xhr.js:117 - How can i solve it index.js:1 Error: Network Error *at createError (createError.js:16) *at XMLHttpRequest.handleError (xhr.js:117 如何在不删除 react index.js 文件中的严格模式的情况下解决严格模式警告 - How can I solve strict mode warning without removing strict mode in react index.js file 如何设置 Babel,然后在命令提示符下点击“npm run dev”,而不会出现“ERROR in./src/js/index.js”? - How do I set up Babel, then hit “npm run dev” in the command prompt without getting the “ERROR in ./src/js/index.js”? 如何在我的 index.js / discord.js 中传递 module.exports - How do I pass module.exports in my index.js / discord.js 如何从组件 index.js (react.js) 中引用 redux 存储中的变量 - How do I reference a variable in redux store from a component index.js (react.js) 如何在Titanium Studio(在index.js中)中包含.js文件? - How do I include a .js file in Titanium studio(in index.js)? 如何让 $node index.js 在我的命令行中运行 index.js? - How can I get $node index.js to run index.js in my command line? 如何解决未捕获的错误:模块构建失败(来自./node_modules/babel-loader/lib/index.js): - How to Solve Uncaught Error: Module build failed (from ./node_modules/babel-loader/lib/index.js):
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM