Repository navigation
feat(cli): srcly findings lists findings by rule with a count - #485
Merged
Merged
Conversation
This was referenced Nov 28, 2026
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
byronwall
force-pushed
the
claude/findings-cli
branch
from
November 28, 2026 05:05
7796689 to
9fefaac
Compare
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.
srcly findings [path] --rule duplicate-typenow prints each hit aspath:line rule messageand a count. An agent can count one rule before and after a cleanup batch without importing a checker in Python. A count reads N/A, with the reason, when the checker did not run.What you'll see
--rulemay be repeated; without it, every finding is listed with a count per rule and a total.--format jsongivescount,found,reason,rules,findingsandnot_checked.srcly reportand shares their cache.--refreshreruns them.null) when a checker for the rule failed, timed out, was configured but not run, or checked no file.Why a new command, not a flag.
reportwrites artifacts, and itsfindings.jsonis a different list (ranked files).explaindrills into one scope.fix --rulecovers only the rules that have fixes. A read-only list over one dataset matchesrefs.Proof
All runs are on this head (
7796689a), on Visual Notesappatorigin/main(d59937fe), in a temporary worktree that borrows the main checkout'snode_modules.srcly findings <visual-notes>/app --rule duplicate-type --refresh(messages cut after the field count):The same run with
--format json(1 of 5 findings shown,known_rulesleft out):{ "root": "<visual-notes>/app", "filter": ["duplicate-type"], "count": 5, "found": 5, "reason": "", "rules": [{ "rule": "duplicate-type", "count": 5, "found": 5, "reason": "" }], "unknown_rules": [], "findings": [ { "path": "src/components/DocumentSidePanel.tsx", "line": 25, "column": 1, "rule": "duplicate-type", "severity": "warning", "tool": "srcly-dup-types", "message": "`DocDetail` copies the exported `DocDetail` in src/services/docs.queries.ts:10 (8 of its 8 fields have the same name and type). Import that type, or derive this one from it (Pick, Omit), so a change to it reaches this file." } ], "not_checked": [] }The done check for a batch: on the
DocDetailcleanup commit (3b320b53) the same command printsduplicate-type: 3.A checker that did not run is never 0 (
SRCLY_FINDINGS_TIMEOUT=0.01):Several rules at once (
--rule TS2322 --rule F401 --rule no-debugger --rule await-in-loop):Without
--rulethe total isTotal: 3538, the sum of the per-checker counts thatsrcly reportprints on the same files: tsc 2853, reachability 579, await-in-loop 101, duplicate types 5. The tsc errors are mostly from the borrowednode_modules.scripts/check.sh server: 647 passed. One new test,tests/test_findings_listing.py.Survey moves:
pnpm survey-gate(base54bf3bba→ head7796689a, so it includes the two layers below) moved onlyserver: traces +5, outcome partial +4, outcome assumed +1 (astgrep.py#rule_ids), stopboundary: filesystem+3, stopfrontier: external-code+81. No analysis code changed. The moves come from new exported functions in theserver/corpus (findings/listing.py,findings/astgrep.py,findings/typescript.py, andsymbols/refs.pyandfindings/duplicate_types.pyfrom the layers below).Review
Codex review (gpt-6.2-sol), 3 rounds, no P0. Round 1: FAIL, 2 P1 and 2 P2; fixed (configured but unrun checkers, zero files checked, shared rule ids, missing text total). Round 2: FAIL, 2 P1 and 2 P2; fixed (switched-off lint rules, ast-grep file coverage, ids with comments). Round 3: FAIL, 3 P1 and 2 P2, listed below. The close step added assertions to the one test for the fixed cases; open cases have no test yet.
Limits
--rule.pgm/data). The fix is a coverage record per rule from each checker.Open findings
"id":key is not read as a rule id. Open: unusual spelling.--refreshavoids it. Pre-existing.Stack: cleanup-loop helpers, layer 3 of 3
This slice:
srcly findings.Why it is its own layer: It is a new command over the findings that the layer below extends, with its own review.
Full story: #482
🤖 Generated with Claude Code