Skip to content

Commit

Permalink
feat(network): add EPROTO to transient http errors (SSL handshake error)
Browse files Browse the repository at this point in the history
  • Loading branch information
livetocode committed May 13, 2023
1 parent b176012 commit 1b4df1b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/core/src/http/isTransientHttpError.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export function isTransientHttpError(statusCode?: number, code?: string) {
}
}
if (
// See all existing error codes here: https://nodejs.org/api/os.html#posix-error-constants
[
'ECONNRESET',
'ECONNABORTED',
Expand All @@ -29,6 +30,7 @@ export function isTransientHttpError(statusCode?: number, code?: string) {
'ETIMEDOUT',
'ENETUNREACH',
'EAI_AGAIN',
'EPROTO'
].includes(code ?? '')
) {
return true;
Expand Down

0 comments on commit 1b4df1b

Please sign in to comment.