feat(api): failRun dead_letter flag — client-forced dead-letter - #11
Open
addadi wants to merge 1 commit into
Open
feat(api): failRun dead_letter flag — client-forced dead-letter#11addadi wants to merge 1 commit into
addadi wants to merge 1 commit into
Conversation
POST /runs/{id}/fail accepts optional "dead_letter": true → skip
max_attempts check, take dead-letter branch (reason client_requested,
next_eligible=impossible, claim SQL excludes it).
Use case: deterministic errors (config/definition problems) can never
succeed on retry. Without this, a task with max_attempts NULL retries
forever, or burns its full attempt budget on an error that is not
transient.
Also wires module tests into zig build test (previously 0 collected):
main.zig test block imports store/api/domain/config; fixes latent
compile errors (compat Dir wrap, ObjectMap.deinit(alloc)) and arena
leaks in 3 auth tests.
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.
Fixes #8
POST /runs/{id}/failaccepts optional"dead_letter": true→ skip max_attempts check, take dead-letter branch immediately (reason=client_requested,next_eligible=impossible, claim SQL excludes). Defaultfalse— existing behavior unchanged.For deterministic errors (config/definition problems) that can never succeed on retry.
Stacked on #9 — includes its test-wiring + compile/leak fixes so the 2 new unit tests run in this branch. Will rebase to just the feature once #9 merges.
Verified locally:
zig buildclean, 20 unit tests pass, e2e 96 passed / 0 failed.