cypress: "Most NODE_OPTIONs are not supported in packaged apps" when using yarn pnp
Current behavior
When I run npm run cypress:open-ct (or run-ct), I get an error [43901:1203/085557.424470:ERROR:node_bindings.cc(276)] Most NODE_OPTIONs are not supported in packaged apps. See documentation for more details.
This might be an Electron issue and it doesn’t seem to affect behaviour for us.
Desired behavior
No error to be thrown
Test code to reproduce
Run the Cypress component tester
Cypress Version
9.1.0
Other
MacOS 11.6 Node v16.0.0
About this issue
- Original URL
- State: open
- Created 5 years ago
- Reactions: 18
- Comments: 38 (6 by maintainers)
I am using yarn pnp … encounter this issue
FYI
NODE_OPTIONSis set by Yarn to add the PnP module loader to Node when you useyarn exec, so if you’re using Yarn PnP you probably shouldn’t unset it. Even if you’re not using PnP it’s probably worth checking what value it’s set to 🤷🏻The error doesn’t seem to affect the test run. But to get rid of it anyway, for me it helped just to unset the environment variable before running cypress.
unset NODE_OPTIONSFWIW, I’m using cypress 8.6.0 on an Intel Mac.
Same here.
Cypress 9.2.1 Mac M1 latest
It seems to have affected cypress testing only on first open after clean install for me.
Same for me.
Cypress Version
Other
Running under VSCode.
I also see this on latest
From my limited experience it doesn’t seem to affect Cypress testing.
@AStoker
As mentioned in https://github.com/cypress-io/cypress/issues/19229#issuecomment-1535906825 quite some time ago, this issue also affects E2E in a Yarn Modern pnp environment.
See https://github.com/cypress-io/github-action/actions/workflows/example-yarn-modern-pnp.yml?query=branch%3Amaster for logs, which include the sequence:
This is Cypress
13.15.2running under Ubuntu24.04.1.Still happening with the latest version.
Adding my voice to the group. Experiencing this with latest version of Cypress (^13.0.0). Our setup is using NX to create an single Angular application. We then set up Yarn PnP, and then ran the cypress command to configure component tests (
yarn nx g @nx/angular:cypress-component-configuration --project=my-project --build-target=my-projectr:build).We then get this
Followed by this
Hello
I have similar issue with running nodemon as debug configuration for VS code on Windows10 for Node.js by using .vscode/launch.json:
In my case:
"runtimeExecutable": "${workspaceFolder}/node_modules/nodemon/bin/nodemon.js", to"runtimeExecutable": "nodemon",Command line changed from:
to:
And it starts to work.
This worked for me.
I had the same warning
revert to cypress 9.2.0 seem to solve this,
npm install cypress@9.2.0