mcp/pkg
Snider 2acf186925 fix(mcp/brain/client): retryableStatus 408+429 + honour Retry-After
retryableStatus now treats 408 (Request Timeout) and 429 (Too Many
Requests) as retryable, matching the PHP-side equivalent. Retry loop
parses Retry-After from the response (seconds form OR HTTP-date),
clamps to 60s max, treats past dates as zero delay.

Tests cover: 408 retried, 429 retried, numeric Retry-After honoured,
past-date Retry-After produces zero sleep, long Retry-After capped.

Co-authored-by: Codex <noreply@openai.com>
Closes tasks.lthn.sh/view.php?id=996
2026-04-25 18:13:07 +01:00
..
mcp fix(mcp/brain/client): retryableStatus 408+429 + honour Retry-After 2026-04-25 18:13:07 +01:00