fix(cli): retry transient connection errors in with_retry (#1132)
## Summary `with_retry()` only retried exceptions when the error was an `HTTPError`. Because of that, transient network errors like `ConnectionError`, `ConnectTimeout`, and `urllib3` connection errors were raised immediately, even though `_is_retriable()` already marks them as retriable. ## Fix Removed the extra `HTTPError` check and let `_is_retriable()` decide whether an exception should be retried. This keeps the existing 429 / `Retry-After` behavior the same while allowing transient connection errors to retry as intended. ## Tests Added tests to verify that: - `ConnectionError` retries and succeeds - `ConnectTimeout` retries and succeeds - `urllib3.ProtocolError` retries and succeeds - non-retriable exceptions still fail immediately Existing `Retry-After` tests continue to pass. Ran: ```bash pytest tests/unit/test_retry_after.py
S
Sridip Basu committed
16dc0d5764794df2cf57ba6c8d9c8248d7d442ea
Parent: ee8734d
Committed by GitHub <noreply@github.com>
on 7/17/2026, 5:32:28 PM