got
>=12.0.0postconditions38functions20last verified2026-06-23coverage score100%Postconditions: what we check
- default · http-errorerrorWhenServer responds with a non-2xx, non-3xx status code and throwHttpErrors is true (default).Throws
HTTPError with code ERR_NON_2XX_3XX_RESPONSE; error.response contains the full responseRequired handlingCaller MUST wrap in try-catch (async/await) or .catch() (promise chain). Inspect error.response.statusCode to distinguish client vs server errors. Do not retry 4xx errors without user intervention (except 408, 413, 429).costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - default · network-errorerrorWhenNetwork-level failure: DNS resolution failure (ENOTFOUND, EAI_AGAIN), connection refused (ECONNREFUSED), connection reset (ECONNRESET), timeout (ETIMEDOUT), no route (ENETUNREACH), or pipe broken (EPIPE). This is thrown after all retries are exhausted.Throws
RequestError with a POSIX error code (e.g. ECONNREFUSED, ETIMEDOUT, ENOTFOUND)Required handlingCaller MUST wrap in try-catch. Check error.code for specific network condition. Got retries these automatically (limit=2 by default) before throwing — the thrown error is from the final attempt. Implement additional retry logic only if default retry is disabled.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - default · timeout-errorerrorWhenOne of the timeout limits (connect, send, response, request, etc.) was exceeded.Throws
TimeoutError (subclass of RequestError) with error.event indicating which phase timed out (e.g. 'connect', 'request', 'response'). Code is ETIMEDOUT.Required handlingCaller MUST wrap in try-catch. Check error.event to understand which phase timed out. ETIMEDOUT is in the default retry error codes — Got will retry before throwing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - default · max-redirects-errorerrorWhenThe server redirected more than maxRedirects times (default: 10).Throws
MaxRedirectsError (subclass of RequestError) with code ERR_TOO_MANY_REDIRECTSRequired handlingCaller MUST wrap in try-catch. This indicates a redirect loop or misconfigured server. Do not retry automatically.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - default · parse-errorerrorWhenServer responds with a 2xx status code, responseType is 'json' (or .json() shortcut is called), and the response body cannot be parsed as JSON. Also triggered when responseType is set to an unknown value. ParseError extends RequestError and includes a .response property with the raw body available at response.rawBody.Throws
ParseError with code ERR_BODY_PARSE_FAILURE. Declared in core/response.d.ts. error.response.rawBody contains the raw Uint8Array. error.message includes the JSON parse error message and the request URL.Required handlingCaller MUST wrap in try-catch. Distinguish from HTTPError by checking error instanceof got.ParseError (or error.code === 'ERR_BODY_PARSE_FAILURE'). This error means the HTTP request succeeded (2xx) but the body was not valid JSON. The raw body is accessible via error.response.rawBody for debugging. ParseError is NOT retried automatically (it's a successful HTTP response with bad content).costmediumin prodimmediate exceptionusers seedegraded performancevisibilitysilent - default · abort-errorwarningWhenAn AbortController's .abort() method is called while the request is in-flight. The AbortController signal is passed via options.signal.Throws
AbortError (subclass of RequestError) with code ERR_ABORTED. This is a Promise rejection, not an event emission.Required handlingCaller MUST wrap in try-catch. Check error.code === 'ERR_ABORTED' or error instanceof got.AbortError. This is commonly used for request cancellation in UI components or when switching users/sessions. Note: AbortError is NOT automatically retried.costlowin prodimmediate exceptionusers seedegraded performancevisibilityvisible - get · http-errorerrorWhenServer responds with non-2xx/3xx status and throwHttpErrors is true (default).Throws
HTTPError with error.response containing status code and bodyRequired handlingCaller MUST wrap in try-catch or .catch(). Check error.response.statusCode.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - get · network-errorerrorWhenDNS failure, connection refused, connection reset, timeout, or unreachable network (after retries).Throws
RequestError (or subclass TimeoutError) with a POSIX error codeRequired handlingCaller MUST wrap in try-catch. GET is in the default retry methods list — got will retry up to 2 times before throwing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - post · http-errorerrorWhenServer responds with non-2xx/3xx status and throwHttpErrors is true (default).Throws
HTTPError with error.response containing status code and bodyRequired handlingCaller MUST wrap in try-catch or .catch(). Check error.response.statusCode.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - post · network-errorerrorWhenDNS failure, connection refused, connection reset, timeout, or unreachable network.Throws
RequestError or TimeoutError with POSIX error codeRequired handlingCaller MUST wrap in try-catch. NOTE: POST is NOT in got's default retry methods list, so the error is thrown after the first failure with no automatic retry.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - post · upload-errorerrorWhenThe request body is a stream and an error occurs reading from that stream.Throws
UploadError (subclass of RequestError)Required handlingCaller MUST wrap in try-catch. Validate body stream before sending.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - put · http-errorerrorWhenServer responds with non-2xx/3xx status and throwHttpErrors is true (default).Throws
HTTPError with error.response containing status code and bodyRequired handlingCaller MUST wrap in try-catch or .catch(). Check error.response.statusCode.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - put · network-errorerrorWhenDNS failure, connection refused, connection reset, timeout, or unreachable network (after retries).Throws
RequestError or TimeoutError with POSIX error codeRequired handlingCaller MUST wrap in try-catch. PUT is in the default retry methods list — got will retry up to 2 times before throwing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - patch · http-errorerrorWhenServer responds with non-2xx/3xx status and throwHttpErrors is true (default).Throws
HTTPError with error.response containing status code and bodyRequired handlingCaller MUST wrap in try-catch or .catch(). Check error.response.statusCode.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - patch · network-errorerrorWhenDNS failure, connection refused, connection reset, timeout, or unreachable network.Throws
RequestError or TimeoutError with POSIX error codeRequired handlingCaller MUST wrap in try-catch. NOTE: PATCH is NOT in got's default retry methods list, so the error is thrown after the first failure with no automatic retry.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - delete · http-errorerrorWhenServer responds with non-2xx/3xx status and throwHttpErrors is true (default).Throws
HTTPError with error.response containing status code and bodyRequired handlingCaller MUST wrap in try-catch or .catch(). Check error.response.statusCode.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - delete · network-errorerrorWhenDNS failure, connection refused, connection reset, timeout, or unreachable network (after retries).Throws
RequestError or TimeoutError with POSIX error codeRequired handlingCaller MUST wrap in try-catch. DELETE is in the default retry methods list — got will retry up to 2 times before throwing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - head · http-errorerrorWhenServer responds with non-2xx/3xx status and throwHttpErrors is true (default).Throws
HTTPError with code ERR_NON_2XX_3XX_RESPONSERequired handlingCaller MUST wrap in try-catch or .catch().costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - head · network-errorerrorWhenDNS failure, connection refused, timeout, or unreachable network (after retries).Throws
RequestError or TimeoutError with POSIX error codeRequired handlingCaller MUST wrap in try-catch. HEAD is in the default retry methods list.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - stream · stream-error-eventerrorWhenAny error occurs during the request: network failure, timeout, HTTP error (when throwHttpErrors is true), read error, or upload error.Throws
RequestError or subclass is emitted as an 'error' event on the stream. This is NOT a Promise rejection. Without an error listener, Node.js will throw an uncaught exception and crash the process.Required handlingCaller MUST attach an 'error' event listener: stream.on('error', handler). Using try-catch around got.stream() does NOT catch these errors. When piping, the error listener must be on the got stream itself, not just the destination stream.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - paginate · paginate-http-errorerrorWhenAny paginated request receives a non-2xx/3xx response and throwHttpErrors is true (default).Throws
HTTPError from the failing request; iteration stops immediatelyRequired handlingCaller MUST wrap the for-await-of loop in try-catch. got.paginate.all() returns a Promise and must be wrapped in try-catch.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - paginate · paginate-network-errorerrorWhenAny paginated request fails with a network error (after retries).Throws
RequestError or subclass; iteration stops immediatelyRequired handlingCaller MUST wrap the for-await-of loop (or got.paginate.all() await) in try-catch.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[5] - extend · inherited-http-errorerrorWhenAny request on the extended instance receives a non-2xx/3xx response and throwHttpErrors is true (default, unless overridden in extend options).Throws
HTTPError — same as base gotRequired handlingCaller MUST wrap in try-catch or .catch(). Extended instances inherit all retry and error-throwing behavior from their parent. Check error.response.statusCode.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - extend · inherited-network-errorerrorWhenAny request on the extended instance fails with a network error (after retries).Throws
RequestError or subclass — same as base gotRequired handlingCaller MUST wrap in try-catch. Error behavior is identical to base got.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[6] - json · json-parse-errorerrorWhenThe HTTP request succeeds with a 2xx status code but the response body is not valid JSON (malformed, truncated, or empty). Common when an upstream service returns HTML error pages (e.g., a proxy 502 with HTML body) with a 2xx status, or when the Content-Type is wrong.Throws
ParseError with code ERR_BODY_PARSE_FAILURE. Declared in core/response.d.ts, exported from index.d.ts. error.response.rawBody contains the raw Uint8Array. error.message includes the JSON parse error and request URL.Required handlingCaller MUST wrap in try-catch. This is NOT the same as HTTPError (which means non-2xx response). ParseError means the HTTP handshake succeeded but data is unusable. Access error.response.rawBody for debugging. Check error.code === 'ERR_BODY_PARSE_FAILURE' or error instanceof ParseError to distinguish from network/HTTP errors. ParseError is NOT retried automatically.costmediumin prodimmediate exceptionusers seedegraded performancevisibilitysilent - json · json-http-errorerrorWhenServer responds with a non-2xx/3xx status code and throwHttpErrors is true (default). This propagates from the underlying got() call.Throws
HTTPError with code ERR_NON_2XX_3XX_RESPONSERequired handlingCaller MUST wrap in try-catch. Same as the underlying got() call behavior.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - buffer · buffer-http-errorerrorWhenServer responds with a non-2xx/3xx status code and throwHttpErrors is true (default).Throws
HTTPError with code ERR_NON_2XX_3XX_RESPONSERequired handlingCaller MUST wrap in try-catch.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - buffer · buffer-network-errorerrorWhenNetwork failure during the request (after retries exhausted).Throws
RequestError or subclass (TimeoutError, etc.)Required handlingCaller MUST wrap in try-catch.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - text · text-http-errorerrorWhenServer responds with a non-2xx/3xx status code and throwHttpErrors is true (default).Throws
HTTPError with code ERR_NON_2XX_3XX_RESPONSERequired handlingCaller MUST wrap in try-catch.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - text · text-network-errorerrorWhenNetwork failure during the request (after retries exhausted).Throws
RequestError or subclass (TimeoutError, etc.)Required handlingCaller MUST wrap in try-catch.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisibleSources[1] - paginate.all · paginate-all-http-errorerrorWhenAny paginated request receives a non-2xx/3xx response and throwHttpErrors is true (default). Iteration halts immediately and the Promise rejects \u2014 already-collected pages are NOT returned to the caller.Throws
HTTPError from the failing request, propagated through Array.fromAsyncRequired handlingCaller MUST wrap `await got.paginate.all(...)` in try-catch or attach .catch(). On rejection, treat the entire result set as missing (no partial array is exposed). Inspect error.response.statusCode to distinguish client vs server failures.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - paginate.all · paginate-all-network-errorerrorWhenAny paginated request fails with a network error (DNS, ECONNREFUSED, ECONNRESET, timeout, etc.) after the configured retry budget is exhausted. Iteration halts and the Promise rejects with the final error.Throws
RequestError or subclass (TimeoutError, ReadError, etc.) propagated through Array.fromAsyncRequired handlingCaller MUST wrap `await got.paginate.all(...)` in try-catch. The Promise rejects exactly once per call site \u2014 there is no per-page error callback. Discard the entire result set on rejection.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - stream.get · stream-alias-error-eventerrorWhenAny error occurs during the request: network failure, timeout, HTTP error (when throwHttpErrors is true, default), read error, or upload error. The returned Duplex stream emits the error as an 'error' event \u2014 it does NOT reject any Promise (the shortcut does not return one).Throws
RequestError (or subclass \u2014 HTTPError, TimeoutError, ReadError, UploadError) emitted as the argument to an 'error' event listener attached to the returned stream. Without an error listener, Node.js raises 'Uncaught Error' and crashes the process.Required handlingCaller MUST attach an 'error' event listener directly to the stream returned from got.stream.<method>() \u2014 stream.on('error', handler) or stream.once('error', handler). Using try-catch around got.stream.get(url) catches NOTHING because the shortcut returns synchronously before any I/O happens. When piping to a destination, use Node's stream.pipeline() (or attach the error listener on the got stream itself, not just the destination \u2014 the destination's 'error' event fires only for its own write errors, not upstream request errors).costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - stream.post · stream-alias-error-eventerrorWhenAny error during the request (network, timeout, HTTPError when throwHttpErrors=true, ReadError, UploadError on a body stream). Emitted as an 'error' event on the returned Duplex stream.Throws
RequestError or subclass \u2014 emitted on stream 'error' event, NOT a Promise rejection.Required handlingCaller MUST attach stream.on('error', handler). try-catch around the got.stream.post() call itself catches nothing. When piping a request body in, attach the listener on the got stream before piping; use stream.pipeline() for the full pipe chain.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - stream.put · stream-alias-error-eventerrorWhenAny error during the request (network, timeout, HTTPError when throwHttpErrors=true, ReadError, UploadError). Emitted on the stream's 'error' event.Throws
RequestError or subclass \u2014 emitted on stream 'error' event, NOT a Promise rejection.Required handlingCaller MUST attach stream.on('error', handler). try-catch on the synchronous call site catches nothing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - stream.patch · stream-alias-error-eventerrorWhenAny error during the request (network, timeout, HTTPError when throwHttpErrors=true, ReadError, UploadError). Emitted on the stream's 'error' event.Throws
RequestError or subclass \u2014 emitted on stream 'error' event, NOT a Promise rejection.Required handlingCaller MUST attach stream.on('error', handler). try-catch on the synchronous call site catches nothing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - stream.head · stream-alias-error-eventerrorWhenAny error during the request (network, timeout, HTTPError when throwHttpErrors=true, ReadError). Emitted on the stream's 'error' event.Throws
RequestError or subclass \u2014 emitted on stream 'error' event, NOT a Promise rejection.Required handlingCaller MUST attach stream.on('error', handler). try-catch on the synchronous call site catches nothing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible - stream.delete · stream-alias-error-eventerrorWhenAny error during the request (network, timeout, HTTPError when throwHttpErrors=true, ReadError, UploadError). Emitted on the stream's 'error' event.Throws
RequestError or subclass \u2014 emitted on stream 'error' event, NOT a Promise rejection.Required handlingCaller MUST attach stream.on('error', handler). try-catch on the synchronous call site catches nothing.costmediumin prodimmediate exceptionusers seeservice unavailablevisibilityvisible
Sources
Every postcondition cites at least one of these. Grouped by source type; numbered to match the footnotes above.
- [1]github.com/sindresorhus/got/blobsindresorhus/got · 8-errors.md
- [2]github.com/sindresorhus/got/blobsindresorhus/got · response.d.ts
- [3]github.com/sindresorhus/got/blobsindresorhus/got · errors.d.ts
- [4]github.com/sindresorhus/got/blobsindresorhus/got · 3-streams.md
- [5]github.com/sindresorhus/got/blobsindresorhus/got · 4-pagination.md
- [6]github.com/sindresorhus/got/blobsindresorhus/got · 10-instances.md
- [7]github.com/sindresorhus/got/blobsindresorhus/got · types.d.ts
- [8]github.com/sindresorhus/got/blobsindresorhus/got · create.ts
Research notes
Curator notes from SOURCES.md captured when the profile was written so you can verify the reasoning, not just the rules.
Got - Nark profile Sources
Package Information
- Package Name: got
- Contract Version: 2.0.0
- Semver Range: >=12.0.0
- Last Verified: 2026-03-12
- Verified Against: got@14.6.6 (installed in fixtures/node_modules)
Primary Sources
Official Documentation
| Document | URL | What it covers |
|---|---|---|
| Errors reference | https://github.com/sindresorhus/got/blob/main/documentation/8-errors.md | Full error class hierarchy, when each is thrown, properties |
| Options reference | https://github.com/sindresorhus/got/blob/main/documentation/2-options.md | throwHttpErrors, retry, timeout options |
| Retry documentation | https://github.com/sindresorhus/got/blob/main/documentation/7-retry.md | Default retry behavior, which methods/status codes are retried |
| Streams documentation | https://github.com/sindresorhus/got/blob/main/documentation/3-streams.md | Stream API error model (events vs rejections) |
| Pagination documentation | https://github.com/sindresorhus/got/blob/main/documentation/4-pagination.md | got.paginate() error propagation |
| Instances documentation | https://github.com/sindresorhus/got/blob/main/documentation/10-instances.md | got.extend() behavior and inheritance |
Source Files Examined (from installed got@14.6.6)
dist/source/core/errors.d.ts— TypeScript declarations for all error classes and their inheritance chaindist/source/core/options.js— Default retry settings (limit, methods, statusCodes, errorCodes)dist/source/core/options.d.ts— Documentation for throwHttpErrors, retry, timeout optionsdist/source/core/calculate-retry-delay.js— Retry delay logic (exponential backoff, RetryError handling)dist/source/as-promise/types.d.ts— CancelError (Promise API only)dist/source/types.d.ts— Got, GotStream, GotPaginate, got.extend() type signatures
Behavioral Claims
Error Class Hierarchy
All got errors inherit from RequestError extends Error:
| Class | code | When thrown | Has response? |
|---|---|---|---|
RequestError | POSIX code | Base class: any request failure | Optional |
HTTPError | ERR_NON_2XX_3XX_RESPONSE | Non-2xx/3xx status when throwHttpErrors: true | Yes |
MaxRedirectsError | ERR_TOO_MANY_REDIRECTS | >10 redirects (configurable) | Yes |
TimeoutError | ETIMEDOUT | Timeout on any phase (connect, request, response, etc.) | No |
ReadError | varies | Failure reading from response stream | Yes |
UploadError | varies | Failure reading from request body stream | No |
CacheError | varies | Cache adapter failure | No |
RetryError | ERR_RETRYING | Manually triggered retry (always causes a new attempt) | No |
AbortError | ERR_ABORTED | Request cancelled via AbortController | No |
CancelError | — | Promise cancelled via .cancel() (Promise API only) | Optional |
Source: dist/source/core/errors.d.ts, dist/source/as-promise/types.d.ts
throwHttpErrors Option
Default: true
Behavior:
- When
true: responses with non-2xx/3xx status throwHTTPError - When
false: responses with 4xx/5xx status resolve with the response object (no throw) - Network errors (
RequestError,TimeoutError, etc.) always throw regardless of this setting
Source: dist/source/core/options.d.ts line 1109-1117:
"Determines if a
got.HTTPErroris thrown for unsuccessful responses. If this is disabled, requests that encounter an error status code will be resolved with theresponseinstead of throwing."
Retry Behavior (Defaults from dist/source/core/options.js)
retry: {
limit: 2,
methods: ['GET', 'PUT', 'HEAD', 'DELETE', 'OPTIONS', 'TRACE'],
// NOTE: POST and PATCH are NOT retried by default
statusCodes: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524],
errorCodes: ['ETIMEDOUT', 'ECONNRESET', 'EADDRINUSE', 'ECONNREFUSED',
'EPIPE', 'ENOTFOUND', 'ENETUNREACH', 'EAI_AGAIN'],
backoffLimit: Infinity,
noise: 100 // ms of jitter
}
Delay formula: min(2^(attempt-1) * 1000, backoffLimit) + random(0, noise)
After retries are exhausted, the final error is thrown to the caller.
Source: dist/source/core/options.js lines 149-187
Stream API Error Model
got.stream() (and got.stream.get(), etc.) returns a Duplex stream, not a Promise.
Errors are emitted as 'error' events, not Promise rejections.
The stream must have an error listener attached. Without one, Node.js will treat it as an uncaught exception.
// CORRECT
const stream = got.stream('https://example.com');
stream.on('error', (error) => { ... });
// WRONG — try-catch does not work for stream errors
try {
const stream = got.stream('https://example.com');
} catch (error) {
// This will NOT catch stream errors
}
The beforeRetry hook is ignored when using the Stream API.
Source: dist/source/types.d.ts (GotStream type), got streams documentation
Pagination API Error Model
got.paginate() returns an AsyncIterableIterator. got.paginate.all() returns a Promise<T[]>.
Errors from individual page requests propagate to the iterator consumer:
for await (const item of got.paginate(...))— must be in try-catchawait got.paginate.all(...)— must be in try-catch
Each page uses the same error behavior as a regular got() call (retries, throwHttpErrors, etc.).
Source: dist/source/types.d.ts (GotPaginate type)
got.extend() Inheritance
got.extend(options) creates a new Got instance with merged defaults. The returned instance:
- Has identical method signatures:
.get(),.post(),.put(),.patch(),.delete(),.head(),.stream(),.paginate(),.extend() - Inherits all error behavior from the parent
- Can override
throwHttpErrors,retry,timeoutetc. in the extend options - Can be further extended:
const api2 = api1.extend({...})
Source: dist/source/types.d.ts (Got type), dist/source/core/options.d.ts
Verification Notes
The contract was verified by reading the TypeScript declarations and source JS of the installed
got@14.6.6 package directly from corpus/packages/got/fixtures/node_modules/got/.
Key changes from stub contract (v1.0.0):
- Added full error hierarchy with all error classes (not just RequestError/HTTPError)
- Added
throwHttpErrors: falseedge case — changes behavior from throw to resolve - Added
streamfunction with correct error model (events, not rejections) - Added
paginatefunction with error propagation through async iteration - Added
extendfunction — documents that error behavior is inherited - Added
headfunction (was missing) - Documented retry defaults precisely: POST/PATCH are NOT retried by default
- Added
upload-errorpostcondition for POST (UploadError on body stream failure) - Added
timeout-errorpostcondition (TimeoutError is a distinct subclass) - Added
max-redirects-errorpostcondition - Updated semver from
>=11.0.0to>=12.0.0(v12 was the ESM-only rewrite)