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
What is this plugin's version? If this is NOT the latest released version, can you try the latest version, please? 17
What is the Cypress version?
What is your operating system? macOS
What is the shell?
What is the Node version? 16.16
What is the NPM version? 8.11
How do you instrument your application? Cypress does not instrument web application code, so you must do it yourself.
Application has been instrumented via nyc instrument --in-place command, then built and served via http-server
When running tests, if you open the web application in a regular browser and open DevTools, do you see window.__coverage__ object? Can you paste a screenshot?
Yes, window.coverage object is visible and reporter contains files.
Is there a .nyc_output folder? Is there a .nyc_output/out.json file? Is it empty? Can you paste at least part of it so we can see the keys and file paths?
yes, out.json as well as report is visible and contains data. Part of it visible on screenshot above.
Do you have any custom NYC settings in package.json (nyc object) or in other NYC config files?
Do you run Cypress tests in a Docker container?
no Describe the bug
After running tests, nyc instrumentation report contains files that are still instrumented, not "reverting" them back to raw state.
nyc instrument --in-place overwrites the source files with instrumented code. The HTML report reads each source file from disk, so it shows the instrumented code. This is expected nyc behavior, not a plugin bug.
To fix it, instrument into a separate folder and serve that folder:
nyc instrument src dist-instrumented
The coverage still points at src/…, so the report shows the original source. #1010 adds a note about this to the README's "Instrument your application" section.
Closing. If the report still shows instrumented code after you switch to a separate folder, open a new issue and include your nyc config and the commands you run.
Activity
docs: warn against nyc instrument --in-place (#861) (#1010)
jennifer-shehane commentedon Nov 2, 2026
nyc instrument --in-placeoverwrites the source files with instrumented code. The HTML report reads each source file from disk, so it shows the instrumented code. This is expectednycbehavior, not a plugin bug.To fix it, instrument into a separate folder and serve that folder:
The coverage still points at
src/…, so the report shows the original source. #1010 adds a note about this to the README's "Instrument your application" section.Closing. If the report still shows instrumented code after you switch to a separate folder, open a new issue and include your
nycconfig and the commands you run.github-actions commentedon Nov 2, 2026
🎉 This issue has been resolved in version 4.1.3 🎉
The release is available on:
Your semantic-release bot 📦🚀