Repository navigation
fix(executor): the runner re-reads its projected attempt token per request, so a task can run past an hour (#1449) - #1451
Merged
Conversation
…quest, so a task can run past an hour (#1449) The task template projects a ServiceAccount token with expirationSeconds: 3600 and points ER_ATTEMPT_TOKEN_FILE at it. exec_task read the file once at startup. Kubelet rotates the file before expiry, but the runner kept presenting the original, so from the 60-minute mark every heartbeat was refused. The runner fenced itself, and the reaper killed the pod with exit 137 ('no heartbeat for 5 minutes'). No task could outlive an hour, and a retry repeated the same death. Found by #558's 10M ingest: tries 2 and 3 each sent their last heartbeat 60m05s after starting. The channel now holds a Credential, either a static env token or a file path, and reads the file on every request. Startup still reads it once, so a missing volume fails immediately. The heartbeat thread and the DuckFleet journal clone the credential rather than a token string. Unit test a_file_credential_presents_the_rotated_token: a rewritten file is the token presented next, and a vanished file is a request error. Co-Authored-By: Claude Opus 5.5 <[email protected]>
athvin
temporarily deployed
to
marketing-preview
November 29, 2026 16:46 — with
GitHub Actions
Inactive
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1449
What
exec-task's channel holds aCredential, either a static env token or a file path, and re-reads the projected token file on every request. It no longer caches the token read at startup.Why
No task could run past an hour. The task template projects a ServiceAccount token with
expirationSeconds: 3600. Kubelet rotates the file, but the runner kept presenting the original, so from the 60-minute mark every heartbeat was refused, the runner fenced itself, and the reaper killed it (exit 137). #558's 10M ingest lost tries 2 and 3 this way: both sent their last heartbeat about 60 minutes in (try 3: 15:12:34 → 16:12:39).Proof
make checkexit 0. Unit testa_file_credential_presents_the_rotated_token: a rewritten file is the token presented next, and a vanished file is a request error. The end-to-end proof is #558's rerun, which needs ingest past an hour: it's in this ledger.Risk & rollback
One file read per channel request (a heartbeat every 30 s). Startup still reads once, so a missing volume fails immediately. Rollback:
git revert <merge-sha>(hour-plus tasks die again).Post-merge ledger
Closed by: agent · session
Claude Code:24d16c2e-fec6-49d8-9797-060338df4848onbrians-MacBook-Pro· 2026-11-29T17:07:39Zmainis green with this change on it — the merge SHA, and the runthat proves it. A later head SHA with this commit as an ancestor counts;
a cancelled run with zero jobs does not: — b328929, rust 46285885196 + frontend 46285885174 success
imagesbuilt, or correctly never ran because nothing that goes intoan image changed: — success, run 46285885178
deployconverged — proved by a line the running process emitted, notby the image digest and not by the workflow conclusion: — its own deploy was superseded by 021881d (Observe the tenant migration result before Helm rolls back #1452), which contains b328929: deploy 46286249159 success, DEPLOY_SHA 021881d
deploy,drift,kind's nightly leg) is green, or knowingly red for a reason that is notthis change: — infra success on b328929
Donethrough the automation rather than byhand, and the issue closed: — fix(executor): any task over an hour is killed — the runner reads its projected attempt token once, and it expires at 3600 s #1449 CLOSED by fix(executor): the runner re-reads its projected attempt token per request, so a task can run past an hour (#1449) #1451 via automation
(a skill, a reference, memory) — or nothing new was learned: — a credential the runner caches must be re-read when its source rotates; projected tokens expire at expirationSeconds
Specific to this change
01a22845…: ingest try 2 started 17:07:48Z and heartbeated at 18:12:52Z (65m04s), past the 60-minute mark where the token-cached runner died twice before (15:12:34 → 16:12:39, killed).Context — plan, discoveries, measurements, files
Plan
Discoveries
Measurements
Files
🤖 Generated with Claude Code