jonah-fleet 1.30.1 → 1.30.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,6 +5,26 @@ All notable changes to `jonah-fleet` will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.30.3](https://github.com/Jonah-Projects/jonah-fleet/compare/v1.30.2...v1.30.3) (2026-10-01)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * **workflows:** mark quota-paused runs as failed and keep routine issues open ([#523](https://github.com/Jonah-Projects/jonah-fleet/issues/523)) ([3115bf8](https://github.com/Jonah-Projects/jonah-fleet/commit/3115bf856f3efa261b29ec33af4e3493e87e4be2))
14
+
15
+ ## [Unreleased] - 2026-10-01
16
+
17
+ ### Bug Fixes
18
+
19
+ * **workflows:** mark quota-paused workflow runs as failed (`exit 1`) with an error annotation and keep routine issues open with `status:quota-paused` instead of falsely reporting success
20
+
21
+ ## [1.30.2](https://github.com/Jonah-Projects/jonah-fleet/compare/v1.30.1...v1.30.2) (2026-09-30)
22
+
23
+
24
+ ### Bug Fixes
25
+
26
+ * **workflows:** respect routine toggle flags in agents-manifest.json during scheduled cron runs ([#509](https://github.com/Jonah-Projects/jonah-fleet/issues/509)) ([dfb188a](https://github.com/Jonah-Projects/jonah-fleet/commit/dfb188a7a4189875e6fb61efb8ea0f0093bbed65))
27
+
8
28
  ## [1.30.1](https://github.com/Jonah-Projects/jonah-fleet/compare/v1.30.0...v1.30.1) (2026-09-25)
9
29
 
10
30
 
package/dist/index.js CHANGED
@@ -4471,10 +4471,6 @@ _Generated by Jonah Fleet local runner on ${hostname}._`;
4471
4471
  cwd,
4472
4472
  stdio: ["ignore", "ignore", "ignore"]
4473
4473
  });
4474
- execSync2(`gh issue close ${issueNumber} --reason completed`, {
4475
- cwd,
4476
- stdio: ["ignore", "ignore", "ignore"]
4477
- });
4478
4474
  } finally {
4479
4475
  if (fs13.existsSync(tmpFile2)) {
4480
4476
  fs13.unlinkSync(tmpFile2);
@@ -4543,8 +4539,37 @@ async function tryMarkLocalRunInterruptedAsync(cwd, issueNumber, hostname, reaso
4543
4539
  return false;
4544
4540
  }
4545
4541
  }
4546
- async function tryReconcileLocalRunIssueAsync(cwd, issueNumber, reportContent, exitCode, hostname, routine) {
4542
+ async function tryReconcileLocalRunIssueAsync(cwd, issueNumber, reportContent, exitCode, hostname, routine, quotaInfo) {
4547
4543
  try {
4544
+ if (quotaInfo?.isQuota) {
4545
+ const resetStr = quotaInfo.resetInfo || "Resets in future window";
4546
+ const quotaCard = [
4547
+ `### \u23F8\uFE0F Milestone: Routine Execution Quota-Paused`,
4548
+ `- **Routine**: \`${routine || "local-routine"}\``,
4549
+ `- **Status**: LLM quota reached (\`${resetStr}\`)`,
4550
+ `- **Runner**: \`local (${hostname})\``,
4551
+ `- **Next Action**: Routine execution paused cleanly. Work will resume on next sweep after quota resets.`
4552
+ ].join("\n");
4553
+ await tryPostLocalRunMilestoneAsync(cwd, issueNumber, quotaCard);
4554
+ const finalBody2 = `${reportContent}
4555
+
4556
+ ---
4557
+ _Generated by Jonah Fleet local runner on ${hostname}._`;
4558
+ const tmpFile2 = path13.join(os2.tmpdir(), `jonah-fleet-run-${issueNumber}-${Date.now()}.md`);
4559
+ await fs13.promises.writeFile(tmpFile2, finalBody2, "utf8");
4560
+ try {
4561
+ await execFileAsync4("gh", ["issue", "edit", String(issueNumber), "--body-file", tmpFile2], { cwd });
4562
+ await execFileAsync4("gh", ["issue", "edit", String(issueNumber), "--add-label", "status:quota-paused", "--remove-label", "status:running"], { cwd });
4563
+ return true;
4564
+ } finally {
4565
+ try {
4566
+ if (fs13.existsSync(tmpFile2)) {
4567
+ await fs13.promises.unlink(tmpFile2);
4568
+ }
4569
+ } catch {
4570
+ }
4571
+ }
4572
+ }
4548
4573
  if (exitCode !== 0) {
4549
4574
  const interruptionCard = formatInterruptionCard({
4550
4575
  routine: routine || "local-routine",
@@ -183,7 +183,7 @@ export declare function tryMarkLocalRunInterruptedAsync(cwd: string, issueNumber
183
183
  * Closes the issue if success, leaves it open with needs-attention if failure.
184
184
  * Fails gracefully if offline or unauthenticated.
185
185
  */
186
- export declare function tryReconcileLocalRunIssueAsync(cwd: string, issueNumber: number, reportContent: string, exitCode: number, hostname: string, routine?: string): Promise<boolean>;
186
+ export declare function tryReconcileLocalRunIssueAsync(cwd: string, issueNumber: number, reportContent: string, exitCode: number, hostname: string, routine?: string, quotaInfo?: QuotaDetectionResult): Promise<boolean>;
187
187
  /**
188
188
  * Reads a freshly generated run report from execution or target directory.
189
189
  * Returns null if no fresh report exists (e.g. file missing or older than run start).
@@ -1 +1 @@
1
- {"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../src/lib/runner.ts"],"names":[],"mappings":"AAgCA,MAAM,WAAW,sBAAsB;IACrC,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC7B,KAAK,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAChC,gBAAgB,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,K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,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,EAAE,MAAM,EAAE,MAAM,CAAC,OAAO,GAAG,MAAM,GAAG,IAAI,GAAG,MAAM,CAEnG;AAED;;;;GAIG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAsDzF;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,qBAAqB,GAAG,MAAM,CAc9E;AAED;;;GAGG;AACH,wBAAsB,uBAAuB,CAC3C,YAAY,EAAE,MAAM,EACpB,OAAO,EAAE,MAAM,GACd,OAAO,CAAC;IAAE,SAAS,EAAE,OAAO,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAkBzE;AAED;;GAEG;AACH,wBAAsB,eAAe,CAAC,OAAO,EAAE,sBAAsB,GAAG,OAAO,CAAC,qBAAqB,CAAC,CAghBrG"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jonah-fleet",
3
- "version": "1.30.1",
3
+ "version": "1.30.3",
4
4
  "description": "Standalone autonomous agent fleet with Symphony orchestration, claim protocols, and continuous improvement loops",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -453,6 +453,11 @@ async function main() {
453
453
  }
454
454
  } else if (parsed.event === 'result' && parsed.result?.response) {
455
455
  console.log(`\n${parsed.result.response}\n`);
456
+ } else if (parsed.event === 'error' || parsed.error) {
457
+ const errMsg =
458
+ parsed.error?.message ||
459
+ (typeof parsed.error === 'string' ? parsed.error : JSON.stringify(parsed.error || parsed));
460
+ console.error(`\n[agent:error] ${errMsg}`);
456
461
  }
457
462
  return;
458
463
  }
@@ -128,6 +128,7 @@ jobs:
128
128
 
129
129
  MODEL="$DEFAULT_MODEL"
130
130
  TIMEOUT="$DEFAULT_TIMEOUT"
131
+ ENABLED="true"
131
132
 
132
133
  if [ -f "agents-manifest.json" ]; then
133
134
  CONFIG_JSON=$(node -e '
@@ -137,14 +138,16 @@ jobs:
137
138
  const r = process.argv[1];
138
139
  const model = m.models?.[r] || m.models?.default;
139
140
  const timeout = m.budgets?.timeoutMinutes?.[r] || m.budgets?.timeoutMinutes?.default;
140
- console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "" }));
141
+ const enabled = m.routines?.[r] !== false;
142
+ console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "", enabled }));
141
143
  } catch (e) {
142
- console.log(JSON.stringify({ model: "", timeout: "" }));
144
+ console.log(JSON.stringify({ model: "", timeout: "", enabled: true }));
143
145
  }
144
146
  ' "$ROUTINE")
145
147
 
146
148
  RESOLVED_MODEL=$(node -e "try { console.log(JSON.parse(process.argv[1]).model || ''); } catch {}" "$CONFIG_JSON")
147
149
  RESOLVED_TIMEOUT=$(node -e "try { console.log(JSON.parse(process.argv[1]).timeout || ''); } catch {}" "$CONFIG_JSON")
150
+ RESOLVED_ENABLED=$(node -e "try { console.log(JSON.parse(process.argv[1]).enabled); } catch {}" "$CONFIG_JSON")
148
151
 
149
152
  if [ -n "$RESOLVED_MODEL" ]; then
150
153
  MODEL="$RESOLVED_MODEL"
@@ -152,13 +155,22 @@ jobs:
152
155
  if [ -n "$RESOLVED_TIMEOUT" ]; then
153
156
  TIMEOUT="$RESOLVED_TIMEOUT"
154
157
  fi
158
+ if [ -n "$RESOLVED_ENABLED" ]; then
159
+ ENABLED="$RESOLVED_ENABLED"
160
+ fi
155
161
  fi
156
162
 
157
163
  echo "model=$MODEL" >> "$GITHUB_OUTPUT"
158
164
  echo "print_timeout=${TIMEOUT}m" >> "$GITHUB_OUTPUT"
159
- echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m"
165
+ echo "enabled=$ENABLED" >> "$GITHUB_OUTPUT"
166
+ echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m, enabled=$ENABLED"
167
+
168
+ if [ "$ENABLED" = "false" ] && [ "${{ github.event_name }}" = "schedule" ]; then
169
+ echo "⏸️ Routine '$ROUTINE' is disabled in agents-manifest.json. Skipping scheduled run."
170
+ fi
160
171
 
161
172
  - name: Initialize Routine Run Issue
173
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
162
174
  id: run-issue
163
175
  env:
164
176
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
@@ -183,6 +195,7 @@ jobs:
183
195
  echo "ROUTINE_ISSUE_NUMBER=$ISSUE_NUMBER" >> "$GITHUB_ENV"
184
196
 
185
197
  - name: Run Analytics Review
198
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
186
199
  timeout-minutes: 50
187
200
  env:
188
201
  GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
@@ -224,7 +237,7 @@ jobs:
224
237
  fi
225
238
 
226
239
  - name: Emit run summary
227
- if: always()
240
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
228
241
  run: |
229
242
  if [ "$QUOTA_PAUSED" = "true" ]; then
230
243
  echo "### ⏸️ Milestone: Routine Execution Quota-Paused" >> "$GITHUB_STEP_SUMMARY"
@@ -238,7 +251,7 @@ jobs:
238
251
  fi
239
252
 
240
253
  - name: Emit Fleet Telemetry (Opt-in)
241
- if: always()
254
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
242
255
  env:
243
256
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
244
257
  TELEMETRY_ENDPOINT: ${{ secrets.JONAH_FLEET_TELEMETRY_ENDPOINT }}
@@ -252,7 +265,7 @@ jobs:
252
265
  fi
253
266
 
254
267
  - name: Reconcile Routine Run Issue
255
- if: always()
268
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
256
269
  env:
257
270
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
258
271
  ISSUE_NUMBER: ${{ steps.run-issue.outputs.issue_number }}
@@ -297,9 +310,9 @@ jobs:
297
310
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
298
311
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
299
312
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
300
- gh issue close "$ISSUE_NUMBER" --reason completed
301
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
302
- exit 0
313
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
314
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
315
+ exit 1
303
316
  fi
304
317
 
305
318
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -130,6 +130,7 @@ jobs:
130
130
 
131
131
  MODEL="$DEFAULT_MODEL"
132
132
  TIMEOUT="$DEFAULT_TIMEOUT"
133
+ ENABLED="true"
133
134
 
134
135
  if [ -f "agents-manifest.json" ]; then
135
136
  CONFIG_JSON=$(node -e '
@@ -139,14 +140,16 @@ jobs:
139
140
  const r = process.argv[1];
140
141
  const model = m.models?.[r] || m.models?.default;
141
142
  const timeout = m.budgets?.timeoutMinutes?.[r] || m.budgets?.timeoutMinutes?.default;
142
- console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "" }));
143
+ const enabled = m.routines?.[r] !== false;
144
+ console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "", enabled }));
143
145
  } catch (e) {
144
- console.log(JSON.stringify({ model: "", timeout: "" }));
146
+ console.log(JSON.stringify({ model: "", timeout: "", enabled: true }));
145
147
  }
146
148
  ' "$ROUTINE")
147
149
 
148
150
  RESOLVED_MODEL=$(node -e "try { console.log(JSON.parse(process.argv[1]).model || ''); } catch {}" "$CONFIG_JSON")
149
151
  RESOLVED_TIMEOUT=$(node -e "try { console.log(JSON.parse(process.argv[1]).timeout || ''); } catch {}" "$CONFIG_JSON")
152
+ RESOLVED_ENABLED=$(node -e "try { console.log(JSON.parse(process.argv[1]).enabled); } catch {}" "$CONFIG_JSON")
150
153
 
151
154
  if [ -n "$RESOLVED_MODEL" ]; then
152
155
  MODEL="$RESOLVED_MODEL"
@@ -154,13 +157,22 @@ jobs:
154
157
  if [ -n "$RESOLVED_TIMEOUT" ]; then
155
158
  TIMEOUT="$RESOLVED_TIMEOUT"
156
159
  fi
160
+ if [ -n "$RESOLVED_ENABLED" ]; then
161
+ ENABLED="$RESOLVED_ENABLED"
162
+ fi
157
163
  fi
158
164
 
159
165
  echo "model=$MODEL" >> "$GITHUB_OUTPUT"
160
166
  echo "print_timeout=${TIMEOUT}m" >> "$GITHUB_OUTPUT"
161
- echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m"
167
+ echo "enabled=$ENABLED" >> "$GITHUB_OUTPUT"
168
+ echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m, enabled=$ENABLED"
169
+
170
+ if [ "$ENABLED" = "false" ] && [ "${{ github.event_name }}" = "schedule" ]; then
171
+ echo "⏸️ Routine '$ROUTINE' is disabled in agents-manifest.json. Skipping scheduled run."
172
+ fi
162
173
 
163
174
  - name: Initialize Routine Run Issue
175
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
164
176
  id: run-issue
165
177
  env:
166
178
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
@@ -190,6 +202,7 @@ jobs:
190
202
  echo "ROUTINE_ISSUE_NUMBER=$ISSUE_NUMBER" >> "$GITHUB_ENV"
191
203
 
192
204
  - name: Run Autowork
205
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
193
206
  timeout-minutes: 60
194
207
  env:
195
208
  GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
@@ -234,7 +247,7 @@ jobs:
234
247
  fi
235
248
 
236
249
  - name: Emit run summary
237
- if: always()
250
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
238
251
  run: |
239
252
  if [ "$QUOTA_PAUSED" = "true" ]; then
240
253
  echo "### ⏸️ Milestone: Routine Execution Quota-Paused" >> "$GITHUB_STEP_SUMMARY"
@@ -248,7 +261,7 @@ jobs:
248
261
  fi
249
262
 
250
263
  - name: Emit Fleet Telemetry (Opt-in)
251
- if: always()
264
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
252
265
  env:
253
266
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
254
267
  TELEMETRY_ENDPOINT: ${{ secrets.JONAH_FLEET_TELEMETRY_ENDPOINT }}
@@ -262,7 +275,7 @@ jobs:
262
275
  fi
263
276
 
264
277
  - name: Verify Atomic Handoff Invariant (PR Existence Guard)
265
- if: always()
278
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
266
279
  env:
267
280
  GH_TOKEN: ${{ github.token }}
268
281
  run: |
@@ -283,7 +296,7 @@ jobs:
283
296
  fi
284
297
 
285
298
  - name: Reconcile Routine Run Issue
286
- if: always()
299
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
287
300
  env:
288
301
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
289
302
  ISSUE_NUMBER: ${{ steps.run-issue.outputs.issue_number }}
@@ -328,9 +341,9 @@ jobs:
328
341
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
329
342
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
330
343
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
331
- gh issue close "$ISSUE_NUMBER" --reason completed
332
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
333
- exit 0
344
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
345
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
346
+ exit 1
334
347
  fi
335
348
 
336
349
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -91,6 +91,7 @@ jobs:
91
91
 
92
92
  MODEL="$DEFAULT_MODEL"
93
93
  TIMEOUT="$DEFAULT_TIMEOUT"
94
+ ENABLED="true"
94
95
 
95
96
  if [ -f "agents-manifest.json" ]; then
96
97
  CONFIG_JSON=$(node -e '
@@ -100,14 +101,16 @@ jobs:
100
101
  const r = process.argv[1];
101
102
  const model = m.models?.[r] || m.models?.default;
102
103
  const timeout = m.budgets?.timeoutMinutes?.[r] || m.budgets?.timeoutMinutes?.default;
103
- console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "" }));
104
+ const enabled = m.routines?.[r] !== false;
105
+ console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "", enabled }));
104
106
  } catch (e) {
105
- console.log(JSON.stringify({ model: "", timeout: "" }));
107
+ console.log(JSON.stringify({ model: "", timeout: "", enabled: true }));
106
108
  }
107
109
  ' "$ROUTINE")
108
110
 
109
111
  RESOLVED_MODEL=$(node -e "try { console.log(JSON.parse(process.argv[1]).model || ''); } catch {}" "$CONFIG_JSON")
110
112
  RESOLVED_TIMEOUT=$(node -e "try { console.log(JSON.parse(process.argv[1]).timeout || ''); } catch {}" "$CONFIG_JSON")
113
+ RESOLVED_ENABLED=$(node -e "try { console.log(JSON.parse(process.argv[1]).enabled); } catch {}" "$CONFIG_JSON")
111
114
 
112
115
  if [ -n "$RESOLVED_MODEL" ]; then
113
116
  MODEL="$RESOLVED_MODEL"
@@ -115,13 +118,22 @@ jobs:
115
118
  if [ -n "$RESOLVED_TIMEOUT" ]; then
116
119
  TIMEOUT="$RESOLVED_TIMEOUT"
117
120
  fi
121
+ if [ -n "$RESOLVED_ENABLED" ]; then
122
+ ENABLED="$RESOLVED_ENABLED"
123
+ fi
118
124
  fi
119
125
 
120
126
  echo "model=$MODEL" >> "$GITHUB_OUTPUT"
121
127
  echo "print_timeout=${TIMEOUT}m" >> "$GITHUB_OUTPUT"
122
- echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m"
128
+ echo "enabled=$ENABLED" >> "$GITHUB_OUTPUT"
129
+ echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m, enabled=$ENABLED"
130
+
131
+ if [ "$ENABLED" = "false" ] && [ "${{ github.event_name }}" = "schedule" ]; then
132
+ echo "⏸️ Routine '$ROUTINE' is disabled in agents-manifest.json. Skipping scheduled run."
133
+ fi
123
134
 
124
135
  - name: Initialize Routine Run Issue
136
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
125
137
  id: run-issue
126
138
  env:
127
139
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
@@ -146,6 +158,7 @@ jobs:
146
158
  echo "ROUTINE_ISSUE_NUMBER=$ISSUE_NUMBER" >> "$GITHUB_ENV"
147
159
 
148
160
  - name: Run Dependency Update Check
161
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
149
162
  timeout-minutes: 25
150
163
  env:
151
164
  GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
@@ -184,7 +197,7 @@ jobs:
184
197
  fi
185
198
 
186
199
  - name: Emit run summary
187
- if: always()
200
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
188
201
  run: |
189
202
  if [ "$QUOTA_PAUSED" = "true" ]; then
190
203
  echo "### ⏸️ Milestone: Routine Execution Quota-Paused" >> "$GITHUB_STEP_SUMMARY"
@@ -198,7 +211,7 @@ jobs:
198
211
  fi
199
212
 
200
213
  - name: Reconcile Routine Run Issue
201
- if: always()
214
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
202
215
  env:
203
216
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
204
217
  ISSUE_NUMBER: ${{ steps.run-issue.outputs.issue_number }}
@@ -243,9 +256,9 @@ jobs:
243
256
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
244
257
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
245
258
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
246
- gh issue close "$ISSUE_NUMBER" --reason completed
247
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
248
- exit 0
259
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
260
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
261
+ exit 1
249
262
  fi
250
263
 
251
264
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -255,9 +255,9 @@ jobs:
255
255
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
256
256
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
257
257
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
258
- gh issue close "$ISSUE_NUMBER" --reason completed
259
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
260
- exit 0
258
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
259
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
260
+ exit 1
261
261
  fi
262
262
 
263
263
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -91,6 +91,7 @@ jobs:
91
91
 
92
92
  MODEL="$DEFAULT_MODEL"
93
93
  TIMEOUT="$DEFAULT_TIMEOUT"
94
+ ENABLED="true"
94
95
 
95
96
  if [ -f "agents-manifest.json" ]; then
96
97
  CONFIG_JSON=$(node -e '
@@ -100,14 +101,16 @@ jobs:
100
101
  const r = process.argv[1];
101
102
  const model = m.models?.[r] || m.models?.default;
102
103
  const timeout = m.budgets?.timeoutMinutes?.[r] || m.budgets?.timeoutMinutes?.default;
103
- console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "" }));
104
+ const enabled = m.routines?.[r] !== false;
105
+ console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "", enabled }));
104
106
  } catch (e) {
105
- console.log(JSON.stringify({ model: "", timeout: "" }));
107
+ console.log(JSON.stringify({ model: "", timeout: "", enabled: true }));
106
108
  }
107
109
  ' "$ROUTINE")
108
110
 
109
111
  RESOLVED_MODEL=$(node -e "try { console.log(JSON.parse(process.argv[1]).model || ''); } catch {}" "$CONFIG_JSON")
110
112
  RESOLVED_TIMEOUT=$(node -e "try { console.log(JSON.parse(process.argv[1]).timeout || ''); } catch {}" "$CONFIG_JSON")
113
+ RESOLVED_ENABLED=$(node -e "try { console.log(JSON.parse(process.argv[1]).enabled); } catch {}" "$CONFIG_JSON")
111
114
 
112
115
  if [ -n "$RESOLVED_MODEL" ]; then
113
116
  MODEL="$RESOLVED_MODEL"
@@ -115,13 +118,22 @@ jobs:
115
118
  if [ -n "$RESOLVED_TIMEOUT" ]; then
116
119
  TIMEOUT="$RESOLVED_TIMEOUT"
117
120
  fi
121
+ if [ -n "$RESOLVED_ENABLED" ]; then
122
+ ENABLED="$RESOLVED_ENABLED"
123
+ fi
118
124
  fi
119
125
 
120
126
  echo "model=$MODEL" >> "$GITHUB_OUTPUT"
121
127
  echo "print_timeout=${TIMEOUT}m" >> "$GITHUB_OUTPUT"
122
- echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m"
128
+ echo "enabled=$ENABLED" >> "$GITHUB_OUTPUT"
129
+ echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m, enabled=$ENABLED"
130
+
131
+ if [ "$ENABLED" = "false" ] && [ "${{ github.event_name }}" = "schedule" ]; then
132
+ echo "⏸️ Routine '$ROUTINE' is disabled in agents-manifest.json. Skipping scheduled run."
133
+ fi
123
134
 
124
135
  - name: Initialize Routine Run Issue
136
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
125
137
  id: run-issue
126
138
  env:
127
139
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
@@ -146,6 +158,7 @@ jobs:
146
158
  echo "ROUTINE_ISSUE_NUMBER=$ISSUE_NUMBER" >> "$GITHUB_ENV"
147
159
 
148
160
  - name: Run Issues Housekeeping
161
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
149
162
  timeout-minutes: 40
150
163
  env:
151
164
  GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
@@ -184,7 +197,7 @@ jobs:
184
197
  fi
185
198
 
186
199
  - name: Emit run summary
187
- if: always()
200
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
188
201
  run: |
189
202
  if [ "$QUOTA_PAUSED" = "true" ]; then
190
203
  echo "### ⏸️ Milestone: Routine Execution Quota-Paused" >> "$GITHUB_STEP_SUMMARY"
@@ -198,7 +211,7 @@ jobs:
198
211
  fi
199
212
 
200
213
  - name: Reconcile Routine Run Issue
201
- if: always()
214
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
202
215
  env:
203
216
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
204
217
  ISSUE_NUMBER: ${{ steps.run-issue.outputs.issue_number }}
@@ -243,9 +256,9 @@ jobs:
243
256
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
244
257
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
245
258
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
246
- gh issue close "$ISSUE_NUMBER" --reason completed
247
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
248
- exit 0
259
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
260
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
261
+ exit 1
249
262
  fi
250
263
 
251
264
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -91,6 +91,7 @@ jobs:
91
91
 
92
92
  MODEL="$DEFAULT_MODEL"
93
93
  TIMEOUT="$DEFAULT_TIMEOUT"
94
+ ENABLED="true"
94
95
 
95
96
  if [ -f "agents-manifest.json" ]; then
96
97
  CONFIG_JSON=$(node -e '
@@ -100,14 +101,16 @@ jobs:
100
101
  const r = process.argv[1];
101
102
  const model = m.models?.[r] || m.models?.default;
102
103
  const timeout = m.budgets?.timeoutMinutes?.[r] || m.budgets?.timeoutMinutes?.default;
103
- console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "" }));
104
+ const enabled = m.routines?.[r] !== false;
105
+ console.log(JSON.stringify({ model: model || "", timeout: timeout ? String(timeout) : "", enabled }));
104
106
  } catch (e) {
105
- console.log(JSON.stringify({ model: "", timeout: "" }));
107
+ console.log(JSON.stringify({ model: "", timeout: "", enabled: true }));
106
108
  }
107
109
  ' "$ROUTINE")
108
110
 
109
111
  RESOLVED_MODEL=$(node -e "try { console.log(JSON.parse(process.argv[1]).model || ''); } catch {}" "$CONFIG_JSON")
110
112
  RESOLVED_TIMEOUT=$(node -e "try { console.log(JSON.parse(process.argv[1]).timeout || ''); } catch {}" "$CONFIG_JSON")
113
+ RESOLVED_ENABLED=$(node -e "try { console.log(JSON.parse(process.argv[1]).enabled); } catch {}" "$CONFIG_JSON")
111
114
 
112
115
  if [ -n "$RESOLVED_MODEL" ]; then
113
116
  MODEL="$RESOLVED_MODEL"
@@ -115,13 +118,22 @@ jobs:
115
118
  if [ -n "$RESOLVED_TIMEOUT" ]; then
116
119
  TIMEOUT="$RESOLVED_TIMEOUT"
117
120
  fi
121
+ if [ -n "$RESOLVED_ENABLED" ]; then
122
+ ENABLED="$RESOLVED_ENABLED"
123
+ fi
118
124
  fi
119
125
 
120
126
  echo "model=$MODEL" >> "$GITHUB_OUTPUT"
121
127
  echo "print_timeout=${TIMEOUT}m" >> "$GITHUB_OUTPUT"
122
- echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m"
128
+ echo "enabled=$ENABLED" >> "$GITHUB_OUTPUT"
129
+ echo "Resolved routine configuration: model=$MODEL, timeout=${TIMEOUT}m, enabled=$ENABLED"
130
+
131
+ if [ "$ENABLED" = "false" ] && [ "${{ github.event_name }}" = "schedule" ]; then
132
+ echo "⏸️ Routine '\''$ROUTINE'\'' is disabled in agents-manifest.json. Skipping scheduled run."
133
+ fi
123
134
 
124
135
  - name: Initialize Routine Run Issue
136
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
125
137
  id: run-issue
126
138
  env:
127
139
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
@@ -146,6 +158,7 @@ jobs:
146
158
  echo "ROUTINE_ISSUE_NUMBER=$ISSUE_NUMBER" >> "$GITHUB_ENV"
147
159
 
148
160
  - name: Run Prompt Optimizer
161
+ if: steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule'
149
162
  timeout-minutes: 35
150
163
  env:
151
164
  GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
@@ -184,7 +197,7 @@ jobs:
184
197
  fi
185
198
 
186
199
  - name: Emit run summary
187
- if: always()
200
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
188
201
  run: |
189
202
  if [ "$QUOTA_PAUSED" = "true" ]; then
190
203
  echo "### ⏸️ Milestone: Routine Execution Quota-Paused" >> "$GITHUB_STEP_SUMMARY"
@@ -198,7 +211,7 @@ jobs:
198
211
  fi
199
212
 
200
213
  - name: Emit Fleet Telemetry (Opt-in)
201
- if: always()
214
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
202
215
  env:
203
216
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
204
217
  TELEMETRY_ENDPOINT: ${{ secrets.JONAH_FLEET_TELEMETRY_ENDPOINT }}
@@ -212,7 +225,7 @@ jobs:
212
225
  fi
213
226
 
214
227
  - name: Reconcile Routine Run Issue
215
- if: always()
228
+ if: always() && (steps.routine-config.outputs.enabled != 'false' || github.event_name != 'schedule')
216
229
  env:
217
230
  GH_TOKEN: ${{ secrets.GH_PAT || github.token }}
218
231
  ISSUE_NUMBER: ${{ steps.run-issue.outputs.issue_number }}
@@ -257,9 +270,9 @@ jobs:
257
270
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
258
271
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
259
272
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
260
- gh issue close "$ISSUE_NUMBER" --reason completed
261
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
262
- exit 0
273
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
274
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
275
+ exit 1
263
276
  fi
264
277
 
265
278
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -339,9 +339,9 @@ jobs:
339
339
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
340
340
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
341
341
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
342
- gh issue close "$ISSUE_NUMBER" --reason completed
343
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
344
- exit 0
342
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
343
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
344
+ exit 1
345
345
  fi
346
346
 
347
347
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -300,9 +300,9 @@ jobs:
300
300
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
301
301
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
302
302
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
303
- gh issue close "$ISSUE_NUMBER" --reason completed
304
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
305
- exit 0
303
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
304
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
305
+ exit 1
306
306
  fi
307
307
 
308
308
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -296,9 +296,9 @@ jobs:
296
296
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
297
297
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
298
298
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
299
- gh issue close "$ISSUE_NUMBER" --reason completed
300
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
301
- exit 0
299
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
300
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
301
+ exit 1
302
302
  fi
303
303
 
304
304
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -326,9 +326,9 @@ jobs:
326
326
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
327
327
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
328
328
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
329
- gh issue close "$ISSUE_NUMBER" --reason completed
330
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
331
- exit 0
329
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
330
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
331
+ exit 1
332
332
  fi
333
333
 
334
334
  REPORT_FILE=".jonah-fleet/run-report.md"
@@ -404,7 +404,6 @@ jobs:
404
404
  "_Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_")
405
405
  gh issue comment "$ISSUE_NUMBER" --body "$PAUSE_COMMENT" || true
406
406
  gh issue edit "$ISSUE_NUMBER" --add-label "status:quota-paused" --remove-label "status:running"
407
- gh issue close "$ISSUE_NUMBER" --reason completed
408
407
 
409
408
  if [ -n "$PR_NUMBER" ]; then
410
409
  gh pr comment "$PR_NUMBER" --body "⏸️ **Peer Review Routine Notice**: LLM quota was reached (${RESET_STR}). The automated review has paused gracefully and will resume automatically on the next scheduled scan sweep once the quota window resets.
@@ -413,8 +412,9 @@ jobs:
413
412
  _Generated by [Antigravity](${SERVER_URL}/${REPOSITORY}/actions/runs/${RUN_ID})_" || true
414
413
  fi
415
414
 
416
- echo "⏸️ Routine run issue #$ISSUE_NUMBER closed with status:quota-paused."
417
- exit 0
415
+ echo "⏸️ Routine run issue #$ISSUE_NUMBER marked with status:quota-paused (kept open)."
416
+ echo "::error::Routine execution quota-paused (${RESET_STR})"
417
+ exit 1
418
418
  fi
419
419
 
420
420
  REPORT_FILE=".jonah-fleet/run-report.md"