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

Command failed with UNKNOWN #16647

Closed
bjornandersson opened this issue May 24, 2021 · 5 comments
Closed

Command failed with UNKNOWN #16647

bjornandersson opened this issue May 24, 2021 · 5 comments
Labels
OS: windows stale no activity on this issue for a long period topic: cypress verify type: bug

Comments

@bjornandersson
Copy link

I'm getting the following error.

I've tried clearing the cypress cache.

Node: v12.18.1
Npm: v6.14.5

npx cypress verify
  cypress:cli:cli cli starts with arguments ["C:\\Program Files\\nodejs\\node.exe","c:\\WS\\git\\betalningsforelaggande-web\\node_modules\\cypress\\bin\\cypress","verify"] +0ms
  cypress:cli NODE_OPTIONS is not set +0ms
  cypress:cli:cli program parsing arguments +3ms
  cypress:cli parsed cli options {} +3ms
  cypress:cli verifying Cypress app +0ms
  cypress:cli checking environment variables +1ms
  cypress:cli checking if executable exists C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress\Cypress.exe +3ms
  cypress:cli Binary is executable? : true +4ms
  cypress:cli binaryDir is  C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress +1ms
  cypress:cli Reading binary package.json from: C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress\resources\app\package.json +0ms
  cypress:cli Found binary version 6.9.1 installed in: C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress +4ms
  cypress:cli could not read binary_state.json file at "C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\binary_state.json" +5ms
  cypress:cli {} +0ms
  cypress:cli is Verified ? undefined +3ms
  cypress:cli force verify +1ms
  cypress:cli running binary verification check 6.9.1 +1ms

  cypress:cli clearing out the verified version +5ms
  cypress:cli needs Xvfb? false +7ms
  cypress:cli spawning, should retry on display problem? false +0ms
  cypress:cli running smoke test +2ms
  cypress:cli using Cypress executable C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress\Cypress.exe +0ms
  cypress:cli smoke test command: C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress\Cypress.exe --smoke-test --ping=859 +1ms
  cypress:cli smoke test timeout 30000 ms +1ms
  cypress:cli Smoke test failed: Error: Command failed with UNKNOWN: C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress\Cypress.exe --smoke-test --ping=859
spawn UNKNOWN
    at ChildProcess.spawn (internal/child_process.js:407:11)
    at Object.spawn (child_process.js:548:9)
    at Object.execa [as exec] (c:\WS\git\betalningsforelaggande-web\node_modules\cypress\node_modules\execa\index.js:80:26)
    at spawn (c:\WS\git\betalningsforelaggande-web\node_modules\cypress\lib\tasks\verify.js:123:33)
    at userFriendlySpawn (c:\WS\git\betalningsforelaggande-web\node_modules\cypress\lib\tasks\verify.js:150:12)
    at runSmokeTest (c:\WS\git\betalningsforelaggande-web\node_modules\cypress\lib\tasks\verify.js:165:10)
    at c:\WS\git\betalningsforelaggande-web\node_modules\cypress\lib\tasks\verify.js:191:29
    at tryCatcher (c:\WS\git\betalningsforelaggande-web\node_modules\bluebird\js\release\util.js:16:23)
    at Promise._settlePromiseFromHandler (c:\WS\git\betalningsforelaggande-web\node_modules\bluebird\js\release\promise.js:547:31)
    at Promise._settlePromise (c:\WS\git\betalningsforelaggande-web\node_modules\bluebird\js\release\promise.js:604:18)
    at Promise._settlePromise0 (c:\WS\git\betalningsforelaggande-web\node_modules\bluebird\js\release\promise.js:649:10)
    at Promise._settlePromises (c:\WS\git\betalningsforelaggande-web\node_modules\bluebird\js\release\promise.js:729:18)
    at Promise._fulfill (c:\WS\git\betalningsforelaggande-web\node_modules\bluebird\js\release\promise.js:673:18)
    at c:\WS\git\betalningsforelaggande-web\node_modules\bluebird\js\release\nodeback.js:42:21
    at CB (c:\WS\git\betalningsforelaggande-web\node_modules\cypress\node_modules\fs-extra\lib\remove\rimraf.js:57:5)
    at c:\WS\git\betalningsforelaggande-web\node_modules\cypress\node_modules\fs-extra\lib\remove\rimraf.js:81:14 {
  errno: 'UNKNOWN',
  code: 'UNKNOWN',
  syscall: 'spawn',
  originalMessage: 'spawn UNKNOWN',
  shortMessage: 'Command failed with UNKNOWN: C:\\Users\\EX13068\\AppData\\Local\\Cypress\\Cache\\6.9.1\\Cypress\\Cypress.exe --smoke-test --ping=859\n' +
    'spawn UNKNOWN',
  command: 'C:\\Users\\EX13068\\AppData\\Local\\Cypress\\Cache\\6.9.1\\Cypress\\Cypress.exe --smoke-test --ping=859',
  exitCode: undefined,
  signal: undefined,
  signalDescription: undefined,
  stdout: '',
  stderr: '',
  all: '',
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
} +83ms
  cypress:cli error message: Command failed with UNKNOWN: C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress\Cypress.exe --smoke-test --ping=859
spawn UNKNOWN +3ms
  ×  Verifying Cypress can run C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress
    → Cypress Version: 6.9.1
Cypress failed to start.

This is usually caused by a missing library or dependency.

The error below should indicate which dependency is missing.

https://on.cypress.io/required-dependencies

If you are using Docker, we provide containers with all required dependencies installed.

----------

Command failed with UNKNOWN: C:\Users\EX13068\AppData\Local\Cypress\Cache\6.9.1\Cypress\Cypress.exe --smoke-test --ping=859
spawn UNKNOWN

----------

Platform: win32 (10.0.17763)
Cypress Version: 6.9.1
@jennifer-shehane
Copy link
Member

Is this happening on your first install? Or this is an upgrade?

I recently saw this error reported for orgs that don't allow opening non-signed exe's on Windows, but I'm not sure that's why this error always shows. #2543

@bjornandersson
Copy link
Author

This is an upgrade from 5.1.0. When it first failed I tried deleteing every instance of cypress I had on my machine.

5.1.0 was working but only if I ran it from a git bash window opened as Administrator. 6.9.1 doesn't work either as Admin or not.

We are behind a HTTP Proxy if that helps? But downloading and installing seems to be working fine.

Also, there are company policys in place that does not allow us to start i.e Chrome with some flags, hence we are left to use Electron.

@minijus
Copy link
Contributor

minijus commented May 27, 2021

Also, there are company policys in place that does not allow us to start i.e Chrome with some flags, hence we are left to use Electron.

@bjornandersson same policies could be reason why launch of Cypress itself fails. spawn UNKNOWN is exactly same message we see when launch is prevented. It could be that executable from previous Cypress version was added to allowed list of applications and the new version is not.

@cypress-app-bot
Copy link
Collaborator

This issue has not had any activity in 180 days. Cypress evolves quickly and the reported behavior should be tested on the latest version of Cypress to verify the behavior is still occurring. It will be closed in 14 days if no updates are provided.

@cypress-app-bot cypress-app-bot added the stale no activity on this issue for a long period label May 17, 2023
@cypress-app-bot
Copy link
Collaborator

This issue has been closed due to inactivity.

@cypress-app-bot cypress-app-bot closed this as not planned Won't fix, can't repro, duplicate, stale May 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OS: windows stale no activity on this issue for a long period topic: cypress verify type: bug
Projects
None yet
Development

No branches or pull requests

4 participants