cypress-io / cypress

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

Vite crashes on Cypress exit #28688

Open dave-shapiro-o opened 10 months ago

dave-shapiro-o commented 10 months ago

Current behavior

Whenever Cypress exits, either when terminated in the terminal in headed (browser) mode, or on teardown when the tests are completed in headless mode, the Vite web server crashes.

Vite version 4.4.9

This is the error when Vite crashes:

node:events:495
      throw er; // Unhandled 'error' event
      ^

Error: read ECONNRESET
    at TCP.onStreamRead (node:internal/stream_base_commons:217:20)
Emitted 'error' event on Socket instance at:
    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) {
  errno: -4077,
  code: 'ECONNRESET',
  syscall: 'read'
}

image

Desired behavior

Vite should not crash.

Test code to reproduce

describe('example', () => {
  it('example', () => {
  })
})

Cypress Version

13.6.1

Node version

18.19.0

Operating System

Windows 11 Version 22H2

Debug Logs

No response

Other

No response

cypress-app-bot commented 1 week ago

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.