Skip to content

[Bugfix #568] Fix pr_exists check for merged PRs - #571

Merged
waleedkadous merged 2 commits into
mainfrom
builder/bugfix-568-pr-exists-porch-check-fails-wh
Feb 26, 2026
Merged

[Bugfix #568] Fix pr_exists check for merged PRs#571
waleedkadous merged 2 commits into
mainfrom
builder/bugfix-568-pr-exists-porch-check-fails-wh

Conversation

@waleedkadous

Copy link
Copy Markdown
Contributor

Summary

Fixes #568

Root Cause

The pr_exists porch check uses gh pr list which defaults to --state open. When a PR is merged before the gate is approved (e.g. architect approves late), the check returns 0 results and blocks the gate.

Fix

Added --state all to the pr_exists check command in all 6 protocol.json files (3 in codev-skeleton/, 3 in codev/) so the check finds PRs regardless of state (open, merged, or closed).

Files changed:

  • codev-skeleton/protocols/spir/protocol.json
  • codev-skeleton/protocols/air/protocol.json
  • codev-skeleton/protocols/aspir/protocol.json
  • codev/protocols/spir/protocol.json
  • codev/protocols/air/protocol.json
  • codev/protocols/aspir/protocol.json

Test Plan

  • Added regression test that validates all protocol.json files contain --state all in pr_exists checks
  • Regression test passes (6 assertions across both codev-skeleton and codev directories)
  • Verified fix is a one-line change per file (--state all added after gh pr list)

@waleedkadous

Copy link
Copy Markdown
Contributor Author

Architect Review

Low-risk bugfix. Adds --state all to all 6 pr_exists check commands across spir/aspir/air protocols in both codev/ and codev-skeleton/. Regression test validates completeness. No other protocols use pr_exists.


Architect review

@waleedkadous
waleedkadous merged commit 815b6cc into main Feb 26, 2026
6 checks passed
@waleedkadous
waleedkadous deleted the builder/bugfix-568-pr-exists-porch-check-fails-wh branch February 26, 2026 15:47
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.

pr_exists porch check fails when PR is merged before gate approval

1 participant