cypress-io / cypress

Fast, easy and reliable testing for anything that runs in a browser.
https://cypress.io
MIT License
46.89k stars 3.18k forks source link

Crash on macOS (Electron) during headful tests #30368

Open taoeffect opened 2 weeks ago

taoeffect commented 2 weeks ago

Current behavior

While running tests using Electron, the browser console crashed:

Screenshot 2024-10-06 at 1 49 14 PM

Here's the crash report: cypresscrash.txt

The tests continued though and completed successfully.

Desired behavior

No response

Test code to reproduce

uh, just running tests in our repo locally on an M3 mac. I'm guessing this error won't happen every time.

Cypress Version

13.14.2

Node version

18.20.2

Operating System

macOS 14.6.1

Debug Logs

No response

Other

No response

stu-crocker commented 2 weeks ago

Update... Forgot to add, this is independent of the browser I use to execute the tests Setting the version in my package-lock.json from * to 13.14.1 here allows me to continue...

"node_modules/@types/cypress": {
      "version": "1.1.3",
      "resolved": "https://registry.npmjs.org/@types/cypress/-/cypress-1.1.3.tgz",
      "integrity": "sha512-OXe0Gw8LeCflkG1oPgFpyrYWJmEKqYncBsD/J0r17r0ETx/TnIGDNLwXt/pFYSYuYTpzcq1q3g62M9DrfsBL4g==",
      "deprecated": "This is a stub types definition for cypress (https://cypress.io). cypress provides its own type definitions, so you don't need @types/cypress installed!",
      "peer": true,
      "dependencies": {
        "cypress": "13.14.1"
      }
    },

I think i'm getting the same, also on M3... my terminal spits out

Cannot read properties of undefined (reading 'split')
TypeError: Cannot read properties of undefined (reading 'split')
    at <embedded>:4432:32174
    at Map.forEach (<anonymous>)
    at i.processBrowserPreRequest (<embedded>:4432:32092)
    at N.shouldIgnorePendingRequest (<embedded>:4432:41782)
    at N.addPendingBrowserPreRequest (<embedded>:4432:40900)
    at d (<embedded>:4432:39953)
    at _ (<embedded>:4432:35792)
    at _.emit (node:events:513:28)
    at f (<embedded>:4491:55225)
    at onEnd (<embedded>:4491:55769)
    at q (<embedded>:4491:53135)
    at N (<embedded>:4491:53761)
    at ee.<anonymous> (<embedded>:4491:55678)
    at ee.emit (node:events:525:35)
    at ee.onRequestError (<embedded>:2050:100575)
    at ClientRequest.emit (node:events:525:35)
    at TLSSocket.socketErrorListener (node:_http_client:502:9)
    at TLSSocket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)