feat(cli): index minimized rule evidence with scores - #1626
Conversation
commit: |
|
React Doctor found no new issues. 🎉 Reviewed by React Doctor for commit |
Interactive terminal E2ETerminal Control verified the built CLI at
|
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 502d273. Configure here.
| collectScoreEvidence: | ||
| rootSpan === undefined | ||
| ? undefined | ||
| : (diagnostics) => collectScoreEvidence({ directory, diagnostics }), |
There was a problem hiding this comment.
Evidence collected when score disabled
Medium Severity
collectScoreEvidence is wired whenever rootSpan exists, but not when !options.noScore. In run-inspect, the callback runs while building the scoreService.compute argument, so it still executes under Score.layerOf(null). Config noScore (and other score-skipped paths with telemetry on) therefore reads source and emits rule.evidence_collected for patterns that never leave the process. Nearby resolveLocalGithubViewerPermission already gates on !options.noScore.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 502d273. Configure here.


Summary
ruleEvidencefield to the same request as the score--no-telemetry, which also skips the score API and share URL, and show a one-time interactive disclosure$reproerskill to turn evidence into synthetic, verified fuzz hypotheses without claiming source recoveryWhy
Rule counts show which diagnostics fire, but not enough context to diagnose false positives or false negatives. Identifier-redacted syntax patterns provide rule-quality evidence without collecting complete source files or data from third-party plugin findings.
Indexing the patterns with the score submission gives maintainers one source of truth for the diagnostic set, score, run metadata, and evidence. The companion score service validates and stores the optional field while remaining compatible with older clients.
The repro workflow preserves the minimization boundary: it invents neutral identifiers and values, prohibits source-identification searches by default, and promotes only verified synthetic cases into the fuzz corpus.
Companion score storage and legal documentation: https://github.com/millionco/doctor/pull/136
Validation
nr testnr lintnr typechecknr format:checknr smoke:json-reportREACT_DOCTOR_NO_TELEMETRY=1 npx react-doctor@latest --verbose --scope changed(100/100, no findings)quick_validate.py