You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We started using cypress with the experimentalJustInTimeCompile flag on true, due to the frequent timeouts we were experiencing on our component testing suite.
While the original timeouts had gone away, in turn we started seeing test failures with the /__cypress/src/spec-0.js not loading in some cases. You can see more details below in logs.
The issues with spec-0.js happen on both dev laptops and CI, and does not appear to be connected to a particular test case.
Desired behavior
No test failures due to the above issue.
Test code to reproduce
Happens on whole test suite randomly, can't share it.
Cypress Version
13.5.0
Node version
20.17.0
Operating System
Ubuntu 20.04 and 22.04
Debug Logs
The following logs contains only the parts that appear to be relevant. I can't post a full one due to the sensitive data contained in it.cypress:network:agent addRequest called { isHttps: false, href: 'http://localhost:8080/__cypress/src/spec-0.js' }cypress:network:agent got family { family: 4, href: 'http://localhost:8080/__cypress/src/spec-0.js' }<i> [webpack-dev-middleware] wait until bundle finished: /__cypress/src/cypress-support-file.js<i> [webpack-dev-middleware] wait until bundle finished: /__cypress/src/spec-0.js
1) An uncaught error was detected outside of a test
0 passing (476ms)
1 failing
1) An uncaught error was detected outside of a test:
Error: The following error originated from your test code, not from Cypress.
> Fetching resource at '/__cypress/src/spec-0.js' failed
When Cypress detects uncaught errors originating from your test code it will automatically fail the current test.
Cypress could not associate this error to any specific test.
We dynamically generated a new test to display this failure.
at xhr.onerror (http://localhost:8080/__cypress/runner/cypress_runner.js:111921:16)
When it doesn't fail, spec-0 is loaded correctly:
cypress:network:agent addRequest called { isHttps: false, href: 'http://localhost:8080/__cypress/src/spec-0.js' }
cypress:network:agent got family { family: 4, href: 'http://localhost:8080/__cypress/src/spec-0.js' }
cypress:server:request received status code & headers on request { requestId: 'request2403', statusCode: 200, headers: { 'content-type': 'application/javascript; charset=utf-8' } }
### Other
_No response_
The text was updated successfully, but these errors were encountered:
dfilipidisz
changed the title
ChunkLoadError: Loading chunk spec-0 failed with experimentalJustInTimeCompile
Loading chunk spec-0 failed with experimentalJustInTimeCompile
Nov 13, 2024
Hi @dfilipidisz. Thank you for opening an issue. Do these timeouts also happen with experimentalJustInTimeCompile=false or does that result in a chunk load error? The behavior described almost looks similar to #15434
Hi @dfilipidisz. Thank you for opening an issue. Do these timeouts also happen with experimentalJustInTimeCompile=false or does that result in a chunk load error? The behavior described almost looks similar to #15434
Yes, with experimentalJustInTimeCompile=false we see the random chunk load errors, that this feature flag is fixing. With experimentalJustInTimeCompile=true, we do not see the chunk load errors, but the issue with the spec-0.js file pops up.
Current behavior
We started using cypress with the
experimentalJustInTimeCompile
flag ontrue
, due to the frequent timeouts we were experiencing on our component testing suite.While the original timeouts had gone away, in turn we started seeing test failures with the
/__cypress/src/spec-0.js
not loading in some cases. You can see more details below in logs.The issues with
spec-0.js
happen on both dev laptops and CI, and does not appear to be connected to a particular test case.Desired behavior
No test failures due to the above issue.
Test code to reproduce
Happens on whole test suite randomly, can't share it.
Cypress Version
13.5.0
Node version
20.17.0
Operating System
Ubuntu 20.04 and 22.04
Debug Logs
When it doesn't fail, spec-0 is loaded correctly:
The text was updated successfully, but these errors were encountered: