fix(miner): close two blind spots in the DEPLOYMENT.md docs-accuracy audit - #5435
Merged
Merged
Conversation
…audit Two real false positives, both currently red on main: - The audit only scanned packages/gittensory-miner/lib and bin for env var reads, missing packages/gittensory-engine/src/miner/ (a real dependency the miner uses for coding-agent driver construction). MINER_CODING_AGENT_CLAUDE_MODEL/CODEX_MODEL/TIMEOUT_MS are genuinely read there (driver-factory.ts) but were flagged as undocumented-in-code. - extractFilePathClaims recorded a markdown link's full target verbatim, including any #anchor fragment, then checked that string against existsSync -- so "README.md#coding-agent-driver-configuration" was checked as a literal (nonexistent) filename instead of "README.md" with a heading fragment. Both were introduced by #5423/#5424 documenting real, working miner config but tripping the audit's own scan gaps, not actual DEPLOYMENT.md drift. Added a regression test for each, verified to fail on the prior code and pass on the fix.
Contributor
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5435 +/- ##
==========================================
- Coverage 88.28% 86.01% -2.27%
==========================================
Files 554 554
Lines 44425 44426 +1
Branches 14663 14663
==========================================
- Hits 39220 38213 -1007
- Misses 3899 4910 +1011
+ Partials 1306 1303 -3
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
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.
Summary
Fixes the CI failure currently red on
main(surfaced on #5430, but unrelated to that PR's own diff -- confirmed by reproducing it on an older, unrelated branch base that never touches these files).Two real false positives in
test/unit/miner-deployment-docs-audit.test.ts/packages/gittensory-miner/lib/deployment-docs-audit.js, both introduced by #5423/#5424 documenting real, working miner config that tripped the audit's own scan gaps -- not actualDEPLOYMENT.mddrift:packages/gittensory-miner/libandbinfor env var reads.MINER_CODING_AGENT_CLAUDE_MODEL/MINER_CODING_AGENT_CODEX_MODEL/MINER_CODING_AGENT_TIMEOUT_MSare genuinely read inpackages/gittensory-engine/src/miner/driver-factory.ts-- a real dependency the miner uses for coding-agent driver construction -- but that directory was never scanned. Now also scansgittensory-engine's miner source (notdist/, which is gitignored and may not be built).extractFilePathClaimsrecorded a markdown link's full target verbatim, including any#anchorfragment, then checked that whole string againstexistsSync.README.md#coding-agent-driver-configurationwas checked as a literal (nonexistent) filename instead ofREADME.mdwith an in-page heading fragment. Now strips the fragment before recording the claim.Test plan
npm run typechecknpm run docs:drift-checknode --check packages/gittensory-miner/lib/deployment-docs-audit.jstest/unit/miner-deployment-docs-audit.test.tssuite green (18/18, up from 15 -- 3 new tests)