Return context error when a retry backoff wait is cancelled #64

Merged
approver_agent merged 1 commits from task/cancel-backoff_79447ef7-e55c-4641-b351-37bc22ffa760 into dev 2026-10-05 11:41:24 -04:00
Member

Maestro task: 79447ef7-e55c-4641-b351-37bc22ffa760 (release correction, Feature 08).

Done-condition

internal/ai/llm/retry.go Retrying.Generate returns the context error when the retry wait is interrupted by cancellation/deadline, not the earlier provider error (a 429 followed by cancellation surfaces the context error; errors.Is against context.Canceled/DeadlineExceeded). A test covers cancellation during backoff. Go quality floor passes. Fix incorporated into dev and release/2026-10-05.

Evidence

  • internal/ai/llm/retry.go returns the context error when the backoff wait is interrupted; test added for cancellation during backoff after a 429.
  • gofmt/vet/go test -race/build pass; no new dependency.
Maestro task: 79447ef7-e55c-4641-b351-37bc22ffa760 (release correction, Feature 08). ## Done-condition internal/ai/llm/retry.go Retrying.Generate returns the context error when the retry wait is interrupted by cancellation/deadline, not the earlier provider error (a 429 followed by cancellation surfaces the context error; errors.Is against context.Canceled/DeadlineExceeded). A test covers cancellation during backoff. Go quality floor passes. Fix incorporated into dev and release/2026-10-05. ## Evidence - internal/ai/llm/retry.go returns the context error when the backoff wait is interrupted; test added for cancellation during backoff after a 429. - gofmt/vet/go test -race/build pass; no new dependency.
dev_agent added 1 commit 2026-10-05 11:36:19 -04:00
Return context error when a retry backoff wait is cancelled
CI / ci (push) Successful in 1m35s
CI / ci (pull_request) Successful in 1m35s
e344522c63
Retrying.Generate returned the earlier provider error (e.g. a 429) when
cancellation or the deadline interrupted the backoff wait, so callers and
the ai_runs record saw rate limiting instead of cancellation. Return the
context error from the interrupted wait instead. Retry counts, backoff and
other error semantics are unchanged.

Maestro task: 79447ef7-e55c-4641-b351-37bc22ffa760

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
overseer added 1 commit 2026-10-05 11:36:19 -04:00
Return context error when a retry backoff wait is cancelled
CI / ci (push) Successful in 1m35s
CI / ci (pull_request) Successful in 1m35s
e344522c63
Retrying.Generate returned the earlier provider error (e.g. a 429) when
cancellation or the deadline interrupted the backoff wait, so callers and
the ai_runs record saw rate limiting instead of cancellation. Return the
context error from the interrupted wait instead. Retry counts, backoff and
other error semantics are unchanged.

Maestro task: 79447ef7-e55c-4641-b351-37bc22ffa760

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
review_agent left a comment
Member

Independent Codex gpt-6-sol review: APPROVED for this exact commit.

Independent Codex gpt-6-sol review: APPROVED for this exact commit.
approver_agent merged commit e6fd24db0a into dev 2026-10-05 11:41:24 -04:00
Sign in to join this conversation.
No Reviewers
No labels
3 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Maniacs_Mansion/MealQuest#64