【问题标题】:Cypress problems with node and cache赛普拉斯的节点和缓存问题
【发布时间】:2020-10-16 22:02:39
【问题描述】:

当我发出命令时:npx cypress open

给出以下错误:

Cypress cannot run because this binary file does not have executable permissions here:

/Users/gianmarx/Library/Caches/Cypress/5.4.0/Cypress.app/Contents/MacOS/Cypress

Reasons this may happen:

- node was installed as 'root' or with 'sudo'
- the cypress npm package as 'root' or with 'sudo'

Please check that you have the appropriate user permissions.

You can also try clearing the cache with 'cypress cache clear' and reinstalling.

----------

Platform: darwin (19.6.0)
Cypress Version: 5.4.0

我尝试安装它,但没有什么总是给我这个错误。

如果我尝试清除缓存它不起作用:

gianmarx@MBPdiGianmarco hoquLDesc % cypress cache clear
zsh: command not found: cypress

【问题讨论】:

    标签: cypress


    【解决方案1】:

    相信通过这些命令可以解决:

    cd ../gianmarx/Library/Caches/Cypress
    cypress cache clear
    

    然后转到您必须启动 cypress 的项目,我可能应该重新安装 cypress。我推荐这个命令:

    yarn add cypress faker --dev
    

    然后尝试再次投射:

    npx cypress open
    

    【讨论】:

      【解决方案2】:

      当我尝试在错误的文件中运行 cypress 时出现此错误。

      确保您在 cypress 文件上的位置正确,以解决此问题

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2020-12-23
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多