-
Notifications
You must be signed in to change notification settings - Fork 1
Handle keepalive pause and avoid auto relabel #25
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
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 | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -163,6 +163,17 @@ async function runKeepaliveGate({ core, github, context, env }) { | |||||||||
| } | ||||||||||
| }; | ||||||||||
|
|
||||||||||
| if (!preGate.ok) { | ||||||||||
| addReason(preGate.reason || 'pre-gate-failed'); | ||||||||||
| summary | ||||||||||
| .addRaw( | ||||||||||
| `Pre-gate check failed: reason=${preGate.reason || 'unknown'} ok=${preGate.ok ? 'true' : 'false'}` | ||||||||||
| ) | ||||||||||
| .addEOL(); | ||||||||||
| } else if (preGate.pendingGate) { | ||||||||||
| summary.addRaw('Gate pending; keepalive will retry once gate concludes.').addEOL(); | ||||||||||
| } | ||||||||||
|
|
||||||||||
| let headSha = ''; | ||||||||||
| if (!pr) { | ||||||||||
| addReason('missing-pr'); | ||||||||||
|
|
@@ -183,30 +194,17 @@ async function runKeepaliveGate({ core, github, context, env }) { | |||||||||
| .filter(Boolean) | ||||||||||
| ); | ||||||||||
|
|
||||||||||
| if (currentLabels.has('agents:pause')) { | ||||||||||
| addReason('keepalive-paused'); | ||||||||||
| summary.addRaw('Keepalive paused by agents:pause label.').addEOL(); | ||||||||||
| } | ||||||||||
|
|
||||||||||
|
Comment on lines
+197
to
+201
|
||||||||||
| if (currentLabels.has('agents:pause')) { | |
| addReason('keepalive-paused'); | |
| summary.addRaw('Keepalive paused by agents:pause label.').addEOL(); | |
| } |
Copilot
AI
Dec 21, 2025
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.
The variable missingLabels is computed but never used. Since the auto-labeling logic has been removed, this line should be deleted as well to avoid unnecessary computation and improve code clarity.
| const missingLabels = requiredLabels.filter((label) => !currentLabels.has(label)); |
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.
The new pause handling checks for
agents:pause, but the rest of the keepalive stack uses theagents:pausedlabel (seescripts/keepalive-runner.jsline 483 and the paused fixture intests/workflows/fixtures/keepalive/paused.json). With the name mismatch, PRs already markedagents:pausedwill not be treated as paused by this gate, so keepalive runs continue even though the pause label is present.Useful? React with 👍 / 👎.