Skip to content

feat: carry the merge-risk checklist into the run's files - #181

Draft
Svilen-Stefanov wants to merge 10 commits into
mainfrom
feat/merge-risk-checklist
Draft

Svilen-Stefanov wants to merge 10 commits into
mainfrom
feat/merge-risk-checklist

Conversation

@Svilen-Stefanov

@Svilen-Stefanov Svilen-Stefanov commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

Goes with licensing https://app.codeboarding.org/CodeBoarding/licensing-aws/pull/80, which answers merge risk and architecture from one warnings engine, and webview https://app.codeboarding.org/CodeBoarding/CodeBoarding-webview/pull/340, which reads what this writes. Now on main; it also carries the schema-2 change from the closed #182.

What

  • The merge-risk request also sends the pull request's title and description (read from the same GET /pulls/{n} that already checks the head), which the deciding model reads. With closed_features_source: false neither the patches nor the description leave the runner.
  • The merge-risk request carries the run's own provider headers, as the guide's does: with its own key, the service decides and reviews on that model and skips Jev, so the code goes to that provider only. Headers that cannot be built fail merge risk instead of falling back to CodeBoarding's models.
  • closed/merge_risk.json is schema 2: the service's status, the checklist answers (or null), reasons that carry each yes's question and, when explained, its sentence and line, sensitive as the list of sensitive questions, and the service's codes when a step fell back (unchecked, unhinted, undecided, unreviewed).
  • The comment line is v: 2: whether the checklist ran (checked), the sensitive questions, size and the reasons' codes. Sentences stay in the artifact.
  • The service's answer is checked strictly, with no defaults for older answers: status must be ok or partial, reasons and sensitive lists, checklist an object or null. Reasons are stored verbatim, so each one's id and relatedTo reach the artifact.
  • The provider headers are built once in main and shared by merge risk, the guide and architecture, instead of twice on two threads. Headers that cannot be built fail all three.
  • The Briefing's unread list no longer counts a merge with stored warnings as read when the ledger predates warningsRead.
  • A run whose checklist did not run (source off, no key, quota, timeout) logs one notice and still stores the answer, so the web platform shows "not assessed" rather than clean.
  • The fallback envelope the Action writes when the architecture request cannot complete says schema 2, matching the service's architecture warnings.
  • README and action.yml describe the new request.

Nothing visible changes in the Action itself.

Before and after on 11 real pull requests

The "after" in licensing #80's comparison (https://app.codeboarding.org/CodeBoarding/licensing-aws/pull/80) went through this branch's own code: run_architecture and run_merge_risk against the dev deploy, with the request each run would have sent, for core #700, #618, webview #328, #339, #334, #330, licensing-aws #69, #66, Action #179, #177 and graph-viewer #105. The table and screenshots are there. Reasons are stored verbatim, so each one's id, relatedTo and shown reach closed/merge_risk.json; the comment line carries level, code and params only.

Before and after on the labelled 28

What closed/merge_risk.json holds for three of the pull requests in licensing #80's examples, which has the full before and after and why:

Ship order

Licensing #80 deployed first, then this release with webview #340. No compatibility: an older line or file reads as "no merge risk recorded".

Second review

  • The service's answer is refused with a named reason when facts lack srcLines, sourceFiles or patches, a reason is not an object with level and code, or sensitive holds a non-string.
  • Notices: a diff too large to send says so (not no_patches), and "some patches left out" now names GitHub only.
  • README says eight questions and what merge risk returns without a model. The pre-warningsRead ledger removal is its own commit.

Tests

pytest tests: 369 passed, 9 skipped. Black 25.9.0 passes.

🤖 Generated with Claude Code

@codeboarding-review

codeboarding-review Bot commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

CodeBoarding review

Status: 1 changed component

See the full change in CodeBoarding.

graph LR
    n_Action_Workflow_and_Analysis_Execution["Action Workflow and Analysis Execution"]
    n_Remote_Review_and_Problem_Ledger["Remote Review and Problem Ledger"]
    classDef added fill:#1f883d,stroke:#0b5d23,color:#ffffff;
    classDef modified fill:#bf8700,stroke:#7d4e00,color:#ffffff;
    classDef deleted fill:#cf222e,stroke:#82071e,color:#ffffff,stroke-dasharray:5 3;
    class n_Remote_Review_and_Problem_Ledger modified;
Loading

download artifacts · run 46504745445

Svilen-Stefanov and others added 4 commits November 30, 2026 15:53
The merge-risk request now sends the pull request's title beside its files, which the
diff checklist reads. closed/merge_risk.json moves to schema 2: the service's status, the
checklist's answers, reasons that carry each yes's question and, when the service gave one,
its sentence and line, the sensitive questions, and why a step did not run. The comment
line moves to v 2 with what the dashboard's level needs: whether the checklist ran, the
sensitive questions, size and the reasons' codes.

A run with source off, or whose checklist did not run, logs one notice and stores the
answer, so the web platform shows the level as not assessed rather than as clean.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…fallback codes

The deciding model reads what the author says the pull request does, so the merge-risk
request now carries the description beside the title. With source off it stays on the
runner with the patches, since a description can quote code. closed/merge_risk.json keeps
the service's codes for a step that fell back: unchecked, unhinted, undecided, unreviewed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A run that brings its own model key now sends the same provider headers on the merge-risk
request as on the guide's, so the service decides and reviews merge risk on that model and
skips the classifier only CodeBoarding's key can reach: the run's code goes to its own
provider and nowhere else. Headers that cannot be built fail merge risk rather than fall
back to CodeBoarding's models.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The service's architecture warnings moved to schema 2 (questions, cited lines, related
warnings). The envelope the Action writes when the request cannot complete says the same
version, so a reader never sees two schemas for one feature.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Svilen-Stefanov
Svilen-Stefanov force-pushed the feat/merge-risk-checklist branch from 9e13103 to ae67a30 Compare November 30, 2026 14:55
@Svilen-Stefanov
Svilen-Stefanov changed the base branch from feat/merge-risk-in-run to main November 30, 2026 14:55
Svilen-Stefanov and others added 6 commits November 30, 2026 18:44
…once

The compact line drops patches, which the webview no longer reads, and indexes
the facts the service always sends. A status other than ok or partial, or
reasons or sensitive that are not lists, now fail merge risk instead of reading
as an empty answer. Reasons are stored verbatim, so an engine id and relatedTo
reach the artifact.

main builds the bearer and the run's provider headers once and hands them to
merge risk, the guide and architecture; headers that cannot be built fail all
three, as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
README and action.yml now say that with closed_features_source false merge
risk leaves out the pull request's description as well as the patches. The
architecture envelope fixture is schema 2.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
_unread no longer counts a merge with stored warnings as read: every ledger
carries warningsRead.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tice

Facts without srcLines, sourceFiles or patches, a reason that is not an object
with a level and a code, and a sensitive list with a non-string are now refused
by name rather than failing on a bare KeyError or being filtered quietly. With
source on, an unchecked no_patches reads as the diff being too large to send;
other codes pass through. A partial patch set is GitHub's doing alone, since an
oversized diff drops every patch. The fixture's checklist reason carries id and
shown, and asks about billing, one of the service's sensitive questions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…thout a model

README drops calls to other services from the checklist and says that an
unsupported provider leaves merge risk with size and tests only. Rewraps the
README and action.yml paragraphs evenly, renames two short test variables, and
the review comment test reads a v2 merge-risk line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Svilen-Stefanov
Svilen-Stefanov force-pushed the feat/merge-risk-checklist branch from f8e4dac to fa81bd8 Compare November 30, 2026 20:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant