Skip to content

fix(core): retry provider failures for about 84s with 10s gap cap - #49441

Merged
rekram1-node merged 1 commit into
v2from
retry-budget
Sep 17, 2026
Merged

rekram1-node merged 1 commit into
v2from
retry-budget

Conversation

@rekram1-node

Copy link
Copy Markdown
Collaborator

Summary

  • raise the session retry allowance from 4 to 10 retries (11 attempts)
  • cap each backoff gap at 10s via Schedule.min with spaced("10 seconds"); the exponential base stays 2s and jitter stays ±20%
  • rewrite the runner tests that encoded the old count to derive their expectations from one RETRY_GAPS constant

Schedule

No retry-after header, every attempt failing:

Retry Gap Jittered Cumulative
1 2s 1.6–2.4s 2s
2 4s 3.2–4.8s 6s
3 8s 6.4–9.6s 14s
4–10 10s each 8–12s 24 … 84s

Total wait 84s nominal (67–101s with jitter), previously 30s with a 16s longest gap. retry-after handling is unchanged: the gap is max(computed, retryAfter) with the existing 15 minute ceiling, so a provider can still stretch a single gap past 10s when it asks to.

Verification

  • packages/core: session-runner 210 pass; full suite passes except the pre-existing local shell/env failures that also fail on v2
  • bun run check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant