Repository navigation
Expose versioned reconciliation JSON for reporting consumers - #382
Conversation
Evaluate claims once for the human and JSON renderers, preserving the existing human output and exit precedence while retaining partial evidence in the machine report. Review and OSCAL validate the schema and process status before using explicit supplying components. Pre-evaluation failures remain exit 2 with stderr diagnostics and no report. Remove reconciled_count and its prose tokens now that consumers read JSON. Validation: 51 check CLI tests, 141 Python tests, all-targets clippy, Ruff, and unchanged default check/review output against the main baseline. Remove drifted, test_a_drifted_report_publishes_no_component_definition, and test_a_report_this_reader_cannot_parse_is_could_not_look from the old human-report parser tests. Machine-contract tests now cover malformed data, unsupported versions, partial reports and explicit component identities.
A range-only hook declared exclusively at stages without a push range cannot supply an enforcement claim. Exclude that declaration before forming the local supplier set, while retaining misplaced diagnostics and independently valid declarations of the same id. JSON partial results now keep review from crediting an explicitly unusable hook. Validation: 52 check CLI tests cover invalid, mixed and independent supplying stages; 29 reporting tests include the review regression. All-targets clippy, Ruff and formatting pass.
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 59 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report❌ Patch coverage is
❌ Your patch status has failed because the patch coverage (93.85%) is below the target coverage (100.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## main #382 +/- ##
==========================================
+ Coverage 94.61% 94.62% +0.01%
==========================================
Files 46 46
Lines 25233 25341 +108
==========================================
+ Hits 23873 23979 +106
- Misses 1360 1362 +2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Python review and OSCAL consumers parse human reconciliation output, which makes wording part of their machine contract. Add
uphold check --jsonwith a versioned report of evaluated claims, suppliers, violations, and unavailable evidence, rendered from the same result as the human report.Migrate both consumers to validated JSON. Review retains the exact principle/rule pairs that reconciled during an evaluated refusal; malformed reports, unsupported versions, unexpected process statuses, and unavailable evidence fail explicitly. Default human output and exit semantics remain compatible. Pre-evaluation failures return exit 2 with stderr and no JSON document.
Known unusable range hooks do not supply partial evidence. A same-named hook with a valid stage or another valid runner still supplies the claim independently.
Validation: 52 check CLI tests, 143 Python tests, all-target Clippy, and normal commit/push checks. Default reconciliation and review output compared byte for byte with main.
Closes #375.