Repository navigation
Add Markdown summaries of review outcomes for CI job pages - #41
Open
iamkhalidd wants to merge 1 commit into
Open
iamkhalidd wants to merge 1 commit into
iamkhalidd wants to merge 1 commit into
Conversation
outcome_markdown renders a ReviewOutcome as Markdown and write_github_step_summary appends it to GITHUB_STEP_SUMMARY. Statuses other than COMPLETED are marked as not a pass, free-text check detail is left out, and server text is escaped.
This branch has not been deployed
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.
Who this helps
Teams that call
wait_for_reviewin CI. Today the job either passes or fails, and to see why a review was incomplete they have to print theReviewOutcomethemselves or open Proofline. This PR puts the answer on the GitHub Actions run page.What it adds
outcome_markdown(outcome) -> strrenders aReviewOutcomeas Markdown: status, a link to the review, the finding count, one row per assessment gap with its reason codes, and one row per unresolved check (name, outcome, lifecycle).write_github_step_summary(outcome, path=None) -> boolappends that Markdown toGITHUB_STEP_SUMMARY. Outside Actions (variable unset) it does nothing and returnsFalse, so the same script runs locally.Decisions
COMPLETED(INCOMPLETE,FAILED,STOPPED,TIMED_OUT) says "Do not treat this result as a pass."CheckGap.detailandunresolved_reasonare left out because they can carry withheld environment values. The summary links to the review instead. Job summaries are visible to anyone who can read the repo, so this felt like the safe default.ProoflineClientandAsyncProoflineClient.Verification
tests/test_summary.py(13 tests): all statuses, gap and check rows, detail/unresolved_reason never shown, hostile check names (pipes, newlines,<img>, links, backticks), unsafe URL not linked, row cap, append to an existing summary, no-op outside Actions, explicit path.ruff check,ruff format --checkandmypy prooflinepass.scripts/check.pyon Windows, because the pinned uv 0.10.12 bootstrap has no Windows checksum, so I ran the same tools fromrequirements-dev.txtin a venv. CI will run the full gate.Example output: