Repository navigation
fix(pr-management): verify CI status check rollup belongs to PR head (part 1 of #2034) #2061
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -102,6 +102,7 @@ def pick( | |
| merge_method: str | None = None, | ||
| pending_not_required: tuple[str, ...] | list[str] = (), | ||
| viewer_known: bool = True, | ||
| ci_outdated_query: bool = False, | ||
| ) -> dict[str, Any]: | ||
| resolve_first = resolve_first or [] | ||
| counts = Counter(str(f.get("severity") or "").lower() for f in findings) | ||
|
|
@@ -142,6 +143,9 @@ def pick( | |
| elif ci_state == "EXPECTED": | ||
| gates.append("CI is waiting for workflow approval — the project's real CI has not run") | ||
| ci_action = "approve the waiting workflow runs (pr-management-triage), then re-run disposition" | ||
| elif ci_outdated_query: | ||
| gates.append("CI rollup cannot be verified — vetted-ops is out of date (latest commit lacks OID)") | ||
| ci_action = "upgrade vetted-ops to update GraphQL queries, then re-run disposition" | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Spec-sync pre-check before pushing a functionality PR
This adds a CI gate and a third meaning of |
||
| elif ci_state != "SUCCESS" and not held_by_auto_merge: | ||
| gates.append(f"CI is {ci_state or 'not reported'}") | ||
| if ci_state == "PENDING" and not real_ci: | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maintainers are immediately informed
ci_outdated_queryreaches onlydisposition(Step 6). Under the same skew,contextstill printsCI: none reported(_ci_linereads onlyrollup_state) and returns"ci": {"state": null, "real_ci": false}, andqueueranks every PR as real-CI-never-ran with no announcement. The maintainer reads the wrong headline for the whole review and learns the cause at the last step. Have_ci_linereturn something likeCI: cannot be verified (vetted-ops query out of date)when the flag is set, and carry the flag in theciobject; a queue announcement can follow in part 2.