Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cypress failed to start on a fresh install using npm #19654

Closed
rahmanfasalu opened this issue Jan 11, 2022 · 9 comments
Closed

Cypress failed to start on a fresh install using npm #19654

rahmanfasalu opened this issue Jan 11, 2022 · 9 comments
Labels
topic: installation Issue during installation or downloading Cypress

Comments

@rahmanfasalu
Copy link

Current behavior

I installed cypress using npm and I got the following error.

It looks like this is your first time using Cypress: 9.2.1


Cypress failed to start.

This may be due to a missing library or dependency. https://on.cypress.io/required-dependencies

Please refer to the error below for more details.

----------

/Users/[username]/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --no-sandbox
/Users/[username]/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --smoke-test
/Users/[username]/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --ping=803

----------

Platform: darwin-x64 (20.5.0)
Cypress Version: 9.2.1

Steps to reproduce

create-react-app cypress-test
cd cypress-test
npm install cypress --save-dev
npx cypress open

Other informations

Os: macOs Big Sur version 11.4
Node : v15.0.1
nvm : 0.35.3
browser: Chrome Version 97.0.4692.71 (Official Build) (x86_64)

This is actually a simple set-up and it should work on a fresh install.

So far tried the following

- restarted the machine 
- npx cypress cache clear
- npx cypress install
- npx cypress verify

but still getting the same error.

Debug logs

cypress:cli:cli cli starts with arguments ["/Users/fasalurahman/.nvm/versions/node/v15.0.1/bin/node","/Users/fasalurahman/Desktop/vitalthings/somnofy-webui/node_modules/.bin/cypress","run"] +0ms
  cypress:cli NODE_OPTIONS is not set +0ms
  cypress:cli:cli program parsing arguments +2ms
  cypress:cli:cli running Cypress with args [ Command { _events: [Object: null prototype] { 'option:browser': [Function (anonymous)], 'option:ci-build-id': [Function (anonymous)], 'option:config': [Function (anonymous)], 'option:config-file': [Function (anonymous)], 'option:env': [Function (anonymous)], 'option:group': [Function (anonymous)], 'option:key': [Function (anonymous)], 'option:headed': [Function (anonymous)], 'option:headless': [Function (anonymous)], 'option:no-exit': [Function (anonymous)], 'option:parallel': [Function (anonymous)], 'option:port': [Function (anonymous)], 'option:project': [Function (anonymous)], 'option:quiet': [Function (anonymous)], 'option:record': [Function (anonymous)], 'option:reporter': [Function (anonymous)], 'option:reporter-options': [Function (anonymous)], 'option:spec': [Function (anonymous)], 'option:tag': [Function (anonymous)], 'option:dev': [Function (anonymous)] }, _eventsCount: 20, _maxListeners: undefined, commands: [], options: [ [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option] ], parent: Command { _events: [Object: null prototype], _eventsCount: 1, _maxListeners: undefined, commands: [Array], options: [Array], parent: null, _allowUnknownOption: false, _args: [], rawArgs: [Array], _scriptPath: '/Users/fasalurahman/Desktop/vitalthings/somnofy-webui/node_modules/.bin/cypress', _name: 'cypress', _optionValues: {}, _storeOptionsAsProperties: true, _passCommandToAction: true, _actionResults: [], _actionHandler: null, _executableHandler: false, _executableFile: null, _defaultCommandName: null, _exitCallback: null, _aliases: [], _hidden: false, _helpFlags: '-h, --help', _helpDescription: 'display help for command', _helpShortFlag: '-h', _helpLongFlag: '--help', _hasImplicitHelpCommand: undefined, _helpCommandName: 'help', _helpCommandnameAndArgs: 'help [command]', _helpCommandDescription: 'display help for command', _usage: '<command> [options]', args: [Array], [Symbol(kCapture)]: false }, _allowUnknownOption: false, _args: [], rawArgs: null, _scriptPath: null, _name: 'run', _optionValues: {}, _storeOptionsAsProperties: true, _passCommandToAction: true, _actionResults: [], _actionHandler: [Function: listener], _executableHandler: false, _executableFile: null, _defaultCommandName: null, _exitCallback: null, _aliases: [], _hidden: false, _helpFlags: '-h, --help', _helpDescription: 'display help for command', _helpShortFlag: '-h', _helpLongFlag: '--help', _hasImplicitHelpCommand: 0, _helpCommandName: 'help', _helpCommandnameAndArgs: 'help [command]', _helpCommandDescription: 'display help for command', _usage: '[options]', _description: 'Runs Cypress tests from the CLI without the GUI', _argsDescription: undefined, exit: true, args: [], [Symbol(kCapture)]: false } ] +0ms
  cypress:cli:cli variable-length opts parsed { args: [ '/Users/fasalurahman/.nvm/versions/node/v15.0.1/bin/node', '/Users/fasalurahman/Desktop/vitalthings/somnofy-webui/node_modules/.bin/cypress', 'run' ], opts: Command { _events: [Object: null prototype] { 'option:browser': [Function (anonymous)], 'option:ci-build-id': [Function (anonymous)], 'option:config': [Function (anonymous)], 'option:config-file': [Function (anonymous)], 'option:env': [Function (anonymous)], 'option:group': [Function (anonymous)], 'option:key': [Function (anonymous)], 'option:headed': [Function (anonymous)], 'option:headless': [Function (anonymous)], 'option:no-exit': [Function (anonymous)], 'option:parallel': [Function (anonymous)], 'option:port': [Function (anonymous)], 'option:project': [Function (anonymous)], 'option:quiet': [Function (anonymous)], 'option:record': [Function (anonymous)], 'option:reporter': [Function (anonymous)], 'option:reporter-options': [Function (anonymous)], 'option:spec': [Function (anonymous)], 'option:tag': [Function (anonymous)], 'option:dev': [Function (anonymous)] }, _eventsCount: 20, _maxListeners: undefined, commands: [], options: [ [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option], [Option] ], parent: Command { _events: [Object: null prototype], _eventsCount: 1, _maxListeners: undefined, commands: [Array], options: [Array], parent: null, _allowUnknownOption: false, _args: [], rawArgs: [Array], _scriptPath: '/Users/fasalurahman/Desktop/vitalthings/somnofy-webui/node_modules/.bin/cypress', _name: 'cypress', _optionValues: {}, _storeOptionsAsProperties: true, _passCommandToAction: true, _actionResults: [], _actionHandler: null, _executableHandler: false, _executableFile: null, _defaultCommandName: null, _exitCallback: null, _aliases: [], _hidden: false, _helpFlags: '-h, --help', _helpDescription: 'display help for command', _helpShortFlag: '-h', _helpLongFlag: '--help', _hasImplicitHelpCommand: undefined, _helpCommandName: 'help', _helpCommandnameAndArgs: 'help [command]', _helpCommandDescription: 'display help for command', _usage: '<command> [options]', args: [Array], [Symbol(kCapture)]: false }, _allowUnknownOption: false, _args: [], rawArgs: null, _scriptPath: null, _name: 'run', _optionValues: {}, _storeOptionsAsProperties: true, _passCommandToAction: true, _actionResults: [], _actionHandler: [Function: listener], _executableHandler: false, _executableFile: null, _defaultCommandName: null, _exitCallback: null, _aliases: [], _hidden: false, _helpFlags: '-h, --help', _helpDescription: 'display help for command', _helpShortFlag: '-h', _helpLongFlag: '--help', _hasImplicitHelpCommand: 0, _helpCommandName: 'help', _helpCommandnameAndArgs: 'help [command]', _helpCommandDescription: 'display help for command', _usage: '[options]', _description: 'Runs Cypress tests from the CLI without the GUI', _argsDescription: undefined, exit: true, args: [], [Symbol(kCapture)]: false } } +104ms
  cypress:cli parsed cli options {} +106ms
  cypress:cli verifying Cypress app +0ms
  cypress:cli checking environment variables +0ms
  cypress:cli checking if executable exists /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress +2ms
  cypress:cli Binary is executable? : true +1ms
  cypress:cli binaryDir is  /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app +0ms
  cypress:cli Reading binary package.json from: /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/Resources/app/package.json +0ms
  cypress:cli Found binary version 9.2.1 installed in: /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app +2ms
  cypress:cli could not read binary_state.json file at "/Users/fasalurahman/Library/Caches/Cypress/9.2.1/binary_state.json" +3ms
  cypress:cli {} +0ms
  cypress:cli is Verified ? undefined +1ms
  cypress:cli running binary verification check 9.2.1 +0ms
It looks like this is your first time using Cypress: 9.2.1


  cypress:cli clearing out the verified version +5ms
  cypress:cli Environment variable ELECTRON_RUN_AS_NODE detected, xvfb is not needed +0ms
  cypress:cli needs Xvfb? false +0ms
  cypress:cli spawning, should retry on display problem? false +0ms
  cypress:cli disabling Electron sandbox +1ms
  cypress:cli running smoke test +0ms
  cypress:cli using Cypress executable /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress +0ms
  cypress:cli smoke test command: /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress --no-sandbox --smoke-test --ping=624 +0ms
  cypress:cli smoke test timeout 30000 ms +0ms
  cypress:cli Smoke test failed: Error: Command failed with exit code 9: /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress --no-sandbox --smoke-test --ping=624
/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --no-sandbox
/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --smoke-test
/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --ping=624
    at makeError (/Users/fasalurahman/Desktop/vitalthings/somnofy-webui/node_modules/cypress/node_modules/execa/lib/error.js:59:11)
    at handlePromise (/Users/fasalurahman/Desktop/vitalthings/somnofy-webui/node_modules/cypress/node_modules/execa/index.js:114:26)
    at processTicksAndRejections (node:internal/process/task_queues:93:5) {
  shortMessage: 'Command failed with exit code 9: /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress --no-sandbox --smoke-test --ping=624',
  command: '/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress --no-sandbox --smoke-test --ping=624',
  exitCode: 9,
  signal: undefined,
  signalDescription: undefined,
  stdout: '',
  stderr: '/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --no-sandbox\n' +
    '/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --smoke-test\n' +
    '/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --ping=624',
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
} +47ms
  cypress:cli error message: /Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --no-sandbox
/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --smoke-test

Cypress failed to start.

This may be due to a missing library or dependency. https://on.cypress.io/required-dependencies

Please refer to the error below for more details.

----------

/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --no-sandbox
/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --smoke-test
/Users/fasalurahman/Library/Caches/Cypress/9.2.1/Cypress.app/Contents/MacOS/Cypress: bad option: --ping=624

----------

Platform: darwin-x64 (20.5.0)
Cypress Version: 9.2.1

Cypress Version

9.2.1

Package Manager

npm

Operating system

Mac

Other

No response

@rahmanfasalu rahmanfasalu added the topic: installation Issue during installation or downloading Cypress label Jan 11, 2022
@mjhenkes
Copy link
Member

I was unable to recreate this issue with the steps provided.

os: Mac OS Big Sur 11.6.2
node: 16.5.0
nvm: 0.39.0

@mjhenkes mjhenkes added the stage: needs information Not enough info to reproduce the issue label Jan 13, 2022
@JawaMatter
Copy link

JawaMatter commented Jan 26, 2022

Same here. Fresh new iMac. Only node js installed.
The very first Cypress installation ended with error.
Guys. I got my new job in a week and I need this mac to work with Cypress 👯 pleeeese :)

Model Name: MacBook Pro
Model Identifier: MacBookPro18,3
Chip: Apple M1 Pro
Total Number of Cores: 8 (6 performance and 2 efficiency)
Memory: 16 GB

No super special steps.
Created a folder for the project and installed cypress. This is the first time.
BUT very interesting fact. I also have iMac Air 2020 with exactly the same OS version and cypress opens. whaaaat.

Lemme check:

  1. Pro 9.3.1 - ERROR
  2. Pro 9.2.0 - ERROR
  3. Air 9.3.1 - works (opens and runs)
  4. Air 9.2.0 - works (opens and runs)
    UPDATE:
  5. Asked a colleague to install Cypress 9.3.1 on the 'same mac version' and it works fine...

We can google-meet, skype-meet, any-way-meet to debug this stuff.

d.galyuk@denyss-mbp cypress-practice % npx cypress install
Installing Cypress (version: 9.3.1)

✔  Downloaded Cypress
✔  Unzipped Cypress
✔  Finished Installation /Users/d.galyuk/Library/Caches/Cypress/9.3.1

You can now open Cypress by running: node_modules/.bin/cypress open

https://on.cypress.io/installing-cypress

d.galyuk@denyss-mbp cypress-practice % npx cypress open
It looks like this is your first time using Cypress: 9.3.1


Cypress failed to start.

This may be due to a missing library or dependency. https://on.cypress.io/required-dependencies

Please refer to the error below for more details.

----------

Command failed with Unknown system error -86: /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/MacOS/Cypress --no-sandbox --smoke-test --ping=140
spawn Unknown system error -86

----------

Platform: darwin-x64 (21.2.0)
Cypress Version: 9.3.1

Cypress Version

9.3.1

Package Manager

npm and npx (no difference)

Operating system

System Version: macOS 12.1 (21C52)
Kernel Version: Darwin 21.2.0

@JawaMatter
Copy link

JawaMatter commented Jan 26, 2022

LOOOL.
You know what I did? :D
I went to the cache where cypress is stored (/Users/d.galyuk/Library/Caches/Cypress/9.2.0)... and tried to open it manually.
The OS said that i need some stuff to install to open it. So I agreed.
Screenshot 2022-01-26 at 05 43 31
After it the Cypress started from here.
And also can be now started from the terminal
Damn. terminal does not allow for OS to show that some soft is needed to run properly.... what a bug.
here ya go
Screenshot 2022-01-26 at 05 49 26

Rosetta is a dynamic binary translator developed by Apple Inc. for macOS, an application compatibility layer between different instruction set architectures. It gives developers and consumers a transition period in which to update their application software to run on newer hardware, by "translating" it to run on the different architecture. The name "Rosetta" is a reference to the Rosetta Stone, the artifact which enabled translation of Egyptian hieroglyphs.[1]

Dear Cypress DEVs... is it good or bad that i've installed rosetta? Any impact on cypress performance?
What happened? New OS + chip did not understood some commands in Cypress to run? so it needed the binary translator? (it says in the notification that:

Rosetta enables Intel-based features to run on Apple silicon Macs. Reopening applications after installation is required to start using Rosetta.

It seems that cypress cannot run natively on the new chip. Cypress have intel-based features and no new-chip-based features?
interesting fact: iMac Air with 2020 chip and the same OS version works fine. Supposedly, maaaaybe some issue here.

@JawaMatter
Copy link

JawaMatter commented Jan 26, 2022

But that's not a WIN :(
The default Cypress tests crash...
Screenshot 2022-01-26 at 06 17 30

**Title:** Error running plugin

**Message:** The following error was thrown by a plugin. We stopped running your tests because a plugin crashed. Please check your plugins file (`/Users/d.galyuk/Job/AQA/projects/cypress931/cypress/plugins/index.js`)

**Details:** Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:67:19)
    at Object.createHash (node:crypto:135:10)
    at module.exports (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/util/createHash.js:135:53)
    at NormalModule._initBuildHash (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:417:16)
    at handleParseError (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:471:10)
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:503:5
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:358:12
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:373:3
    at iterateNormalLoaders (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:214:10)
    at iterateNormalLoaders (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:221:10)
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:236:3
    at context.callback (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:111:13)
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/babel-loader/lib/index.js:59:71
    at processTicksAndRejections (node:internal/process/task_queues:96:5)

**Stack trace:**
Error: The following error was thrown by a plugin. We stopped running your tests because a plugin crashed. Please check your plugins file (`/Users/d.galyuk/Job/AQA/projects/cypress931/cypress/plugins/index.js`)
    at Object.get (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/packages/server/lib/errors.js:1043:15)
    at EventEmitter.handleError (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/packages/server/lib/plugins/index.js:210:20)
    at EventEmitter.emit (node:events:394:28)
    at ChildProcess.<anonymous> (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/packages/server/lib/plugins/util.js:19:22)
    at ChildProcess.emit (node:events:394:28)
    at emit (node:internal/child_process:920:12)
    at processTicksAndRejections (node:internal/process/task_queues:84:21)

I think rosetta did not save us.
index.js is basic:

/// <reference types="cypress" />
// ***********************************************************
// This example plugins/index.js can be used to load plugins
//
// You can change the location of this file or turn off loading
// the plugins file with the 'pluginsFile' configuration option.
//
// You can read more here:
// https://on.cypress.io/plugins-guide
// ***********************************************************

// This function is called when a project is opened or re-opened (e.g. due to
// the project's config changing)

/**
 * @type {Cypress.PluginConfig}
 */
// eslint-disable-next-line no-unused-vars
module.exports = (on, config) => {
  // `on` is used to hook into various events Cypress emits
  // `config` is the resolved Cypress config
}

if you will try to run such 'failed' cypress ...

Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db

Why you should do it regularly:
https://github.com/browserslist/browserslist#browsers-data-updating

The following error was thrown by a plugin. We stopped running your tests because a plugin crashed. Please check your plugins file (`/Users/d.galyuk/Job/AQA/projects/cypress931/cypress/plugins/index.js`)

 Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:67:19)
    at Object.createHash (node:crypto:135:10)
    at module.exports (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/util/createHash.js:135:53)
    at NormalModule._initBuildHash (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:417:16)
    at handleParseError (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:471:10)
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:503:5
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:358:12
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:373:3
    at iterateNormalLoaders (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:214:10)
    at iterateNormalLoaders (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:221:10)
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:236:3
    at context.callback (/Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:111:13)
    at /Users/d.galyuk/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/babel-loader/lib/index.js:59:71
    at processTicksAndRejections (node:internal/process/task_queues:96:5)

Screenshot 2022-01-26 at 17 47 06

@JawaMatter
Copy link

JawaMatter commented Jan 26, 2022

this fixed the problem but, man, that was a huge dance with the 'shaman drum'
https://www.cypress.io/blog/2021/01/20/running-cypress-on-the-apple-m1-silicon-arm-architecture-using-rosetta-2/
please make native mac chip support

System Version: macOS 12.1 (21C52)
Kernel Version: Darwin 21.2.0
Cypress: 9.3.1
nvm 0.39.1
npm 6.14.15
node 12.22.9 (specific for Rosetta 2 and workaround)
IMAGE 2022-01-26 20:25:40

@thomvaill
Copy link

Yep,

I propose to close this issue and to continue the discussion on these two possible solutions:

@linediconsine
Copy link

linediconsine commented Jan 28, 2022

I can reproduce on:

intel macOs Monterey
% node -v
v17.4.0
% nvm -v
0.38.0

The following error was thrown by a plugin. We stopped running your tests because a plugin crashed. Please check your plugins file (`/Users/marcoo/Documents/breeze-e2e-testing/cypress/plugins/index.js`)

 Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:67:19)
    at Object.createHash (node:crypto:130:10)
    at module.exports (/Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/util/createHash.js:135:53)
    at NormalModule._initBuildHash (/Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:417:16)
    at handleParseError (/Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:471:10)
    at /Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:503:5
    at /Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/webpack/lib/NormalModule.js:358:12
    at /Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:373:3
    at iterateNormalLoaders (/Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:214:10)
    at iterateNormalLoaders (/Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:221:10)
    at /Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:236:3
    at context.callback (/Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/loader-runner/lib/LoaderRunner.js:111:13)
    at /Users/marcoo/Library/Caches/Cypress/9.3.1/Cypress.app/Contents/Resources/app/node_modules/babel-loader/lib/index.js:59:71
    at processTicksAndRejections (node:internal/process/task_queues:96:5)

For me, a temporary workaround for me is to revert to 9.2.0

npm install [email protected]

I hope this help

@cypress-bot cypress-bot bot added stage: backlog and removed stage: needs information Not enough info to reproduce the issue labels Apr 29, 2022
@flotwig
Copy link
Contributor

flotwig commented Jun 29, 2022

Closing this issue - M1 support was added in Cypress 10.2.0 and no workaround is needed for it to work with npm install

@flotwig flotwig closed this as completed Jun 29, 2022
@art-c0der
Copy link

LOOOL. You know what I did? :D I went to the cache where cypress is stored (/Users/d.galyuk/Library/Caches/Cypress/9.2.0)... and tried to open it manually. The OS said that i need some stuff to install to open it. So I agreed. Screenshot 2022-01-26 at 05 43 31 After it the Cypress started from here. And also can be now started from the terminal Damn. terminal does not allow for OS to show that some soft is needed to run properly.... what a bug. here ya go Screenshot 2022-01-26 at 05 49 26

Rosetta is a dynamic binary translator developed by Apple Inc. for macOS, an application compatibility layer between different instruction set architectures. It gives developers and consumers a transition period in which to update their application software to run on newer hardware, by "translating" it to run on the different architecture. The name "Rosetta" is a reference to the Rosetta Stone, the artifact which enabled translation of Egyptian hieroglyphs.[1]

Dear Cypress DEVs... is it good or bad that i've installed rosetta? Any impact on cypress performance? What happened? New OS + chip did not understood some commands in Cypress to run? so it needed the binary translator? (it says in the notification that:

Rosetta enables Intel-based features to run on Apple silicon Macs. Reopening applications after installation is required to start using Rosetta.

It seems that cypress cannot run natively on the new chip. Cypress have intel-based features and no new-chip-based features? interesting fact: iMac Air with 2020 chip and the same OS version works fine. Supposedly, maaaaybe some issue here.

Helped for me! Thanks @JawaMatter 👏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: installation Issue during installation or downloading Cypress
Projects
None yet
Development

No branches or pull requests

7 participants