fix: preserve successive CLI regression findings - #89
Conversation
|
@fatihcvs is attempting to deploy a commit to the priyanshu's projects Team on Vercel. A member of the Team first needs to authorize it. |
CodewithJha
left a comment
There was a problem hiding this comment.
Thanks @fatihcvs — this hits #68 / MUT-020 cleanly: successive findings allocate cli_discovered_violation[_N].json via exclusive create, so prior regressions and pre-existing user files are preserved. The first filename stays compatible; mutiny test discovers both; replace is documented without a new --force flag. GitHub Actions green on 3.11/3.12; ignoring Vercel auth.
|
Merged — thank you @fatihcvs. Exactly the kind of CLI reliability fix Mutiny needs: successive verified findings keep their own regression files, exclusive create avoids races, and the original If you'd like to continue working on Mutiny, these would be good related areas to look at:
No pressure — only if you want another one. |
Keep the contributor-facing audit index accurate now that MUT-017/020/023/024/025/037 shipped. Co-authored-by: Cursor <cursoragent@cursor.com>
Summary
Fixes #68. Successive verified findings now use the first free
cli_discovered_violation[_N].jsonpath instead of overwriting earlier regressions. Exclusive file creation protects against races between writers; the artifact name, returned regression ID and event path follow the allocated filename.The first filename remains compatible with existing samples and hosted-sync fixtures. The CLI guide documents numbering and intentional replacement via backup/removal/re-run; no new
--forceoption is introduced.Type of change
Checklist
Test plan
pytest tests/unit -q: 378 passed on Windows / Python 3.12.14 with uv on PATH and UTF-8 enabled.The two new cases failed before the fix. They run two actual local campaigns against the in-process demo adapter, verify distinct artifacts and unchanged previous bytes (including a pre-existing user file), check event/ID consistency, and replay both findings through
run_tests. Model mutation is explicitly disabled in these tests; no live provider testing is claimed.