-
Notifications
You must be signed in to change notification settings - Fork 22
[m] feat(workflow): add delegation watchdog to auto-recover stalled non-task nodes #437
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
dbdae3e
5d30755
71bdb12
0b7a030
c6d90e0
cc0fd80
1d15092
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 | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -1109,6 +1109,8 @@ export const BOSUN_PR_WATCHDOG_TEMPLATE = { | |||||||||
| trustedAuthors: "", | ||||||||||
| allowTrustedFixes: false, | ||||||||||
| allowTrustedMerges: false, | ||||||||||
| delegationWatchdogTimeoutMs: 300000, | ||||||||||
| delegationWatchdogMaxRecoveries: 1, | ||||||||||
| }, | ||||||||||
| nodes: [ | ||||||||||
| node("trigger", "trigger.schedule", "Poll Every 90s", { | ||||||||||
|
|
@@ -2248,6 +2250,8 @@ export const SDK_CONFLICT_RESOLVER_TEMPLATE = { | |||||||||
| "7. Ensure no conflict markers (`<<<<<<<`, `=======`, `>>>>>>>`) remain", | ||||||||||
| sdk: "auto", | ||||||||||
| timeoutMs: "{{timeoutMs}}", | ||||||||||
| delegationWatchdogTimeoutMs: "{{delegationWatchdogTimeoutMs}}", | ||||||||||
| delegationWatchdogMaxRecoveries: "{{delegationWatchdogMaxRecoveries}}", | ||||||||||
|
Comment on lines
+2253
to
+2254
|
||||||||||
| delegationWatchdogTimeoutMs: "{{delegationWatchdogTimeoutMs}}", | |
| delegationWatchdogMaxRecoveries: "{{delegationWatchdogMaxRecoveries}}", | |
| delegationWatchdogTimeoutMs: 900000, | |
| delegationWatchdogMaxRecoveries: 3, |
| Original file line number | Diff line number | Diff line change | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -68,7 +68,9 @@ export const TASK_LIFECYCLE_TEMPLATE = { | |||||||||||||
| claimRenewIntervalMs: 60000, | ||||||||||||||
| defaultSdk: "auto", | ||||||||||||||
| defaultTargetBranch: "origin/main", | ||||||||||||||
| taskTimeoutMs: 21600000, // 6 hours | ||||||||||||||
| taskTimeoutMs: 21600000, | ||||||||||||||
| delegationWatchdogTimeoutMs: 300000, | ||||||||||||||
| delegationWatchdogMaxRecoveries: 1, // 6 hours | ||||||||||||||
|
Comment on lines
+71
to
+73
|
||||||||||||||
| taskTimeoutMs: 21600000, | |
| delegationWatchdogTimeoutMs: 300000, | |
| delegationWatchdogMaxRecoveries: 1, // 6 hours | |
| taskTimeoutMs: 21600000, // 6 hours | |
| delegationWatchdogTimeoutMs: 300000, | |
| delegationWatchdogMaxRecoveries: 1, // max recovery attempts for delegation watchdog |
Copilot
AI
Mar 25, 2026
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.
This file changes workflow templates. The repo has a sync test (tests/demo-defaults-sync.test.mjs) that requires regenerating ui/demo-defaults.js and site/ui/demo-defaults.js via node tools/generate-demo-defaults.mjs after template updates. Please run the generator and commit the updated demo-defaults outputs, otherwise CI will fail.
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.
Even after fixing the test nesting, these new watchdog tests set
ctxwithout any task context (taskId/taskTitle), butaction.run_agentonly enters the workflow-delegation path whenhasTaskContextis true. As written, the handler will fall back toengine.services.agentPool.*and never callengine.execute/getRunHistory, so the assertions about delegated runs won’t hold. Provide a minimal task payload (e.g.,taskId+taskTitle) or adjust the test to target the non-delegated agent path.