Skip to content

Commit 487ec95

Browse files
fix(queue): let draft-dodge reach the shared pause gate so stand-downs are audited
Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent 82148ee commit 487ec95

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/queue/processors.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5866,15 +5866,15 @@ async function handlePullRequestWebhookEvent(
58665866
// Draft-dodge guard (#converted-to-draft): a contributor converting an OPEN PR to draft cannot use
58675867
// draft state to keep a gate-rejected PR alive. When a prior gate failure exists for the PR's current
58685868
// headSha (and the block has not been maintainer-overridden), close the PR immediately — the gate
5869-
// verdict stands and does not reset on draft conversion. Skipped when the agent is unconfigured or
5870-
// paused (the gate doesn't act on paused repos) and for owner / automation PRs.
5869+
// verdict stands and does not reset on draft conversion. Skipped when the agent is unconfigured and for
5870+
// owner / automation PRs. Pause/freeze/dry-run are enforced inside evaluateCloseEnforcementGate (same as
5871+
// the other 4 close-enforcement guards) so a paused stand-down is audited (#6604), not silently skipped.
58715872
if (
58725873
payload.action === "converted_to_draft" &&
58735874
installationId &&
58745875
pr.headSha &&
58755876
pr.state === "open" &&
58765877
isAgentConfigured(settings.autonomy) &&
5877-
!settings.agentPaused &&
58785878
!isProtectedAutomationAuthor(pr.authorLogin)
58795879
) {
58805880
// Deliberately UNCAUGHT here: closeDraftDodgeAttemptIfBlocked catches every operation that should

0 commit comments

Comments
 (0)