Commit 264beb5
committed
Fix: Improve error handling to distinguish network errors from TLS failures
Separates specific network transport errors (`ETIMEDOUT`, `ECONNRESET`)
from genuine TLS handshake failures.
The previous approach incorrectly categorized lower-level connection
issues as "TLS errors," leading to misleading diagnostics for end-users.
This change ensures accurate reporting based on the error pattern:
- "tls handshake": Protocol/certificate issue.
- "etimedout" / "timed out": Network timeout/availability.
- "econnreset": Connection forcefully reset by host/intermediary.1 parent fa8a54d commit 264beb5
2 files changed
+41
-16
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
256 | 256 | | |
257 | 257 | | |
258 | 258 | | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
259 | 265 | | |
260 | 266 | | |
261 | 267 | | |
| |||
914 | 920 | | |
915 | 921 | | |
916 | 922 | | |
917 | | - | |
918 | | - | |
919 | | - | |
| 923 | + | |
| 924 | + | |
| 925 | + | |
| 926 | + | |
| 927 | + | |
| 928 | + | |
| 929 | + | |
| 930 | + | |
| 931 | + | |
| 932 | + | |
| 933 | + | |
| 934 | + | |
| 935 | + | |
| 936 | + | |
| 937 | + | |
| 938 | + | |
920 | 939 | | |
921 | | - | |
922 | | - | |
923 | | - | |
924 | | - | |
925 | | - | |
| 940 | + | |
| 941 | + | |
| 942 | + | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
926 | 946 | | |
927 | 947 | | |
928 | 948 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| 49 | + | |
49 | 50 | | |
50 | 51 | | |
51 | 52 | | |
| |||
1189 | 1190 | | |
1190 | 1191 | | |
1191 | 1192 | | |
1192 | | - | |
| 1193 | + | |
1193 | 1194 | | |
1194 | 1195 | | |
1195 | 1196 | | |
1196 | 1197 | | |
1197 | 1198 | | |
1198 | 1199 | | |
1199 | 1200 | | |
1200 | | - | |
| 1201 | + | |
| 1202 | + | |
| 1203 | + | |
| 1204 | + | |
| 1205 | + | |
1201 | 1206 | | |
1202 | 1207 | | |
1203 | 1208 | | |
| 1209 | + | |
1204 | 1210 | | |
1205 | 1211 | | |
1206 | 1212 | | |
1207 | 1213 | | |
| 1214 | + | |
1208 | 1215 | | |
1209 | 1216 | | |
1210 | 1217 | | |
1211 | 1218 | | |
| 1219 | + | |
1212 | 1220 | | |
1213 | 1221 | | |
1214 | 1222 | | |
1215 | | - | |
1216 | | - | |
| 1223 | + | |
| 1224 | + | |
1217 | 1225 | | |
1218 | 1226 | | |
1219 | 1227 | | |
| |||
1231 | 1239 | | |
1232 | 1240 | | |
1233 | 1241 | | |
1234 | | - | |
1235 | | - | |
1236 | | - | |
1237 | | - | |
| 1242 | + | |
1238 | 1243 | | |
1239 | 1244 | | |
1240 | 1245 | | |
| |||
0 commit comments