Commit 60eb2a2
Treat transient network errors as AbortError instead of BugError
Renames isARetryableNetworkError to isTransientNetworkError for clarity
and exports it for reuse in fetchApiVersions error handling. This fixes
6,941+ production errors that were incorrectly classified as bugs.
Changes:
- Renamed isARetryableNetworkError -> isTransientNetworkError
- Added JSDoc explaining these are transient network errors
- Exported function for reuse across the codebase
- Enhanced detection patterns to include TLS/cert errors, premature close, timeouts
- Updated fetchApiVersions to classify network errors as AbortError
Network errors now properly classified include:
- TLS certificate validation failures (main issue with 6,941 occurrences)
- Connection timeouts (ETIMEDOUT)
- Connection resets (ECONNRESET)
- DNS failures (ENOTFOUND, getaddrinfo)
- Socket disconnects and premature closes
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>1 parent 22f3630 commit 60eb2a2
File tree
3 files changed
+37
-5
lines changed- .changeset
- packages/cli-kit/src
- private/node
- public/node/api
3 files changed
+37
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
71 | | - | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
72 | 78 | | |
73 | 79 | | |
74 | 80 | | |
| |||
82 | 88 | | |
83 | 89 | | |
84 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
85 | 99 | | |
86 | 100 | | |
87 | 101 | | |
| |||
105 | 119 | | |
106 | 120 | | |
107 | 121 | | |
108 | | - | |
| 122 | + | |
109 | 123 | | |
110 | 124 | | |
111 | 125 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
| |||
182 | 183 | | |
183 | 184 | | |
184 | 185 | | |
185 | | - | |
186 | | - | |
187 | | - | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
188 | 193 | | |
189 | 194 | | |
| 195 | + | |
190 | 196 | | |
191 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
192 | 205 | | |
193 | 206 | | |
194 | 207 | | |
| |||
0 commit comments