Repository navigation
Closed as duplicate
Closed as duplicate
Copy link
Labels
type/bugType bug: the code does not do what it must
Description
Requested by the owner, 2026-10-10 ("file the issues"). The defect turned up while the v0.2.33 changelog was consolidated (#1547). The v0.2.33 entry for #873 says that no Ruff finding reaches review.md or findings.json yet.
Problem
Checked at main (69c99cf, v0.2.33).
devops review path,branchandprrun Ruff as review evidence (feat(review): ruff and mypy run as review evidence with the project's settings, advisory rules report only on changed lines, and changed functions show complexity before and after #873, feat(review): ruff and mypy review evidence with project settings #1523). Ruff runs on the reviewed files' resolved absolute paths (RuffScanner.build_command,src/devops_cli/security/ruff.py:241-244), so its SARIF names each file by afile:///…URI._parse_sarif_result_to_finding(ruff.py:40-80) keeps that URI as the finding's location.normalize_finding_path(src/devops_cli/review/location.py:28) treatsfile:///…as a relative path, andvalidate_locationrejects it aspath-not-in-commit(location.py:77-82).- So admission drops every Ruff finding, including those of the
[advisory] rules(BLE001by default). The mypy and complexity findings name relative paths and are admitted. - Reproduced at 69c99cf on a scratch repository holding one
try/except Exception: pass:run_ruff_scanreturns S110 and BLE001 atfile:///…/pkg/a.py.validate_locationrejects both aspath-not-in-commit.- A path review's grouped advisory title carries the URI too:
[BLE001] 1 advisory finding(s) in file:///….
tests/test_review_ruff_mypy_evidence.pyfeeds the parser SARIF with a relative"uri": "src/pricing.py"(line 223), so no test sees Ruff's real output.
Proposed remedy
- Ruff's
file://locations become paths relative to the reviewed tree before admission, for example withPath.from_uriand then made relative to the worktree. Admission, the diff-hunk filter and the advisory grouping then all seepkg/a.py.
Acceptance criteria
- A review of a file with a Ruff finding, run on Ruff's real SARIF output, admits the finding at the file's path in the reviewed tree. It is reported in
review.mdandfindings.json. - A branch or pull request review reports an
[advisory] rulesfinding inside the diff's hunks and drops one outside them. - A path review's grouped advisory names the file by its path in the tree.
- The evidence tests read Ruff's own SARIF, with its absolute
file://URIs, rather than a hand-written relative one. -
changelog.d/<issue>.mdunder### Fixedsays that Ruff's findings, the advisory rules' included, now reachreview.mdandfindings.json.
Feasibility
Reproduced at 69c99cf by running the real run_ruff_scan and validate_location on a scratch git repository. The fix fits one pull request: Ruff's location parsing in src/devops_cli/security/ruff.py, or normalize_finding_path, and its tests.
Metadata
Metadata
Assignees
Labels
type/bugType bug: the code does not do what it must
Type
Projects
- StatusShow more project fieldsDone
Activity
dan-petty-bot commentedon Oct 10, 2026
Intake placed this item to the backlog: at intake only a critical fix goes into a release; a release start pulls Ready items in, P0 features first.
Ruff's file:// SARIF locations are mis-normalized as relative paths, causing validate_location to reject every Ruff finding, so the shipped feature silently drops all its output.An entire evidence channel (Ruff findings including advisory rules like BLE001) is non-functional in shipped v0.2.33, but it is a missing signal rather than a data-loss or outage.Users relying on Ruff advisory rules for security signals in reviews receive no findings at all, defeating the purpose of the evidence-first review.The fix is confined to Ruff's location parsing in ruff.py or normalize_finding_path plus updating the evidence tests to use real SARIF output, fitting one pull request.dan-petty commentedon Oct 11, 2026
Closed as a duplicate of #873:
This candidate fixes a problem introduced by item 873, making it a defect found in work delivered by that item rather than a duplicate.If it is not a duplicate, reopen it: intake then places it without the duplicate check.
fix(roadmap): intake calls a candidate a duplicate only when it asks …