chore: Replace nyc with c8 for coverage - #209
Open
TwitchBronBron wants to merge 1 commit into
Open
Conversation
nyc@15 is unmaintained. c8 uses V8's native coverage instead. Pinned to
c8@10, the last line supporting Node 18 (c8@12 requires >=20.19).
- 429 -> 387 total packages
- Overrides reduced from 7 to 3, plus one dependency range tightened.
Stripped all overrides, re-audited from scratch, and reapplied only what
still reproduces:
- serialize-javascript ^7 (high: RCE + DoS, via mocha)
- vscode-languageserver-protocol / -types 3.17.5 - NOT security pins.
Floating to 3.18.3 exposes types via conditional `exports`, unreadable
under moduleResolution:node, which broke the build with 108 errors.
- thenby pinned 1.3.4 (was ^1.3.4). 1.4.1 changed firstBy/thenBy generic
signatures, breaking src/testHelpers.spec.ts. It's a direct devDep so an
override is rejected with EOVERRIDE; the range itself had to be pinned.
brace-expansion@^1/@^2, js-yaml, fast-uri, istanbul-lib-processinfo, and
@babel/core are resolved by current transitive versions.
Coverage was not previously at 100% here (check-coverage is false) and stays
comparable: statements 96.24% -> 97.28%, branches 88.44% -> 88.38%,
functions 99.48% -> 99.3%. Shifts are istanbul-vs-V8 granularity.
Verified after a clean install: build, lint, and the audit gate all clean,
0 vulnerabilities. Coveralls still reads ./coverage/lcov.info.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
nyc@15is unmaintained. c8 uses V8's native coverage instead. Pinned to c8@10, the last line supporting Node 18 (c8@12requires>=20.19).Overrides: 7 → 3, plus one dependency range tightened. Stripped all overrides, re-audited from a clean install, and reapplied only what genuinely reproduces:
serialize-javascript: ^7— still required (high: RCE + CPU-exhaustion DoS, via mocha)vscode-languageserver-protocol/-types: 3.17.5— not security pins. Floating to 3.18.3 exposes types through conditionalexportsthat TypeScript can't read undermoduleResolution: node, breaking the build with 108 errors.thenbypinned to1.3.4(was^1.3.4) — 1.4.1 changed thefirstBy/thenBygeneric signatures, breakingsrc/testHelpers.spec.ts. It's a direct devDependency, so an override is rejected withEOVERRIDE; the range itself had to be pinned.Dropped as obsolete:
brace-expansion@^1/@^2,js-yaml,fast-uri,istanbul-lib-processinfo,@babel/core. 0 vulnerabilities and theaudit-cigate passes.Coverage note: this repo was not previously at 100% and
check-coverageisfalse. Numbers stay comparable — statements 96.24% → 97.28%, branches 88.44% → 88.38%, functions 99.48% → 99.3%. Shifts are istanbul-vs-V8 instrumentation granularity, not a change in what's tested.Verified after a clean
rm -rf node_modules package-lock.json && npm install:npm test,npm run build,npm run lint, andnpm run auditall clean. Coveralls still reads./coverage/lcov.info.🤖 Generated with Claude Code