Commit 4be5743
committed
Fix misleading error message for 503 long backoff and type safety
- isRateLimitExceeded: include 429 (was only catching 403), so the
'rate limit exceeded' message correctly covers all HTTP rate-limit
responses while 503 long-backoff gets its own message
- Long-wait error message differentiates 429/403 rate limit from 503
server backoff: 'GitHub API requested a long backoff before retrying.'
- options.signal: replace unsafe cast (as AbortSignal | undefined) with
nullish coalescing (?? undefined) to preserve null-safety
- Test callback: updated to async to match Promise<void> contract1 parent 470f3c0 commit 4be5743
2 files changed
Lines changed: 11 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
250 | 250 | | |
251 | 251 | | |
252 | 252 | | |
253 | | - | |
| 253 | + | |
254 | 254 | | |
255 | 255 | | |
256 | 256 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
40 | 43 | | |
41 | 44 | | |
42 | 45 | | |
| |||
145 | 148 | | |
146 | 149 | | |
147 | 150 | | |
148 | | - | |
149 | | - | |
150 | | - | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
151 | 157 | | |
152 | 158 | | |
153 | 159 | | |
| |||
163 | 169 | | |
164 | 170 | | |
165 | 171 | | |
166 | | - | |
| 172 | + | |
167 | 173 | | |
168 | 174 | | |
169 | 175 | | |
| |||
0 commit comments