cypress
cypress copied to clipboard
webpack 5 error when module contains dynamic import: "Automatic publicPath is not supported in this browser"
Current behavior
Same as https://github.com/cypress-io/cypress/issues/18435. This issue was marked as fixed but I can still reproduce using the latest version of Cypress. Full reduced test case: https://github.com/OliverJAsh/cypress-webpack-5-public-path-error/tree/upgrade
Unfortunately I had to open a new issue because https://github.com/cypress-io/cypress/issues/18435 has been locked.
Desired behavior
No response
Test code to reproduce
https://github.com/OliverJAsh/cypress-webpack-5-public-path-error/tree/upgrade
Cypress Version
10.9.0
Node version
16.3.0
Operating System
macOS 12.6
Debug Logs
No response
Other
No response
Confirming that I also still get the same issue with: Cypress 10.9.0 Node: 14.17.3 locally MacOS: 12.6 - M1 chip in ci, docker base image: cypress/base:14.17.3
So still I use the workaround suggested here
@OliverJAsh thanks for the reproduction again
Any news on this one? It's still reproducible in version 13.6.3.
We have a library that we're using in two apps. The library uses dynamic imports. For one of the apps we're now creating tests in Cypress and also import code from the library in the test files. Those tests will not run due to this webpack 5 error. In the library we don't have set a publicPath so it uses 'auto' by default. The apps both work as expected, but inside a Cypress test we get this error.