oven-sh/bun · error · TypeError

ClientAborted

ClientAborted

Error message

ClientAborted

What it means

The client-side peer (e.g., a browser or downstream client) aborted the connection or request mid-flight. This is a sentinel indicating the remote client disconnected before the response could be fully delivered.

Solutions

  1. Check if the client has a short timeout and the server response is too slow
  2. Investigate client-side network issues or premature connection termination
  3. Log and ignore these errors as they typically indicate normal user behavior (page navigation, cancellation)
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at src/http/error.rs:38 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of oven-sh/bun@8c5296ac45 (2026-08-16). Data as JSON: /api/errors/2e36ca4e51e50c34. Report an issue: GitHub.

Appendix: source

Thrown at src/http/error.rs:38

    #[error("HTTP2EnhanceYourCalm")]
    HTTP2EnhanceYourCalm,
    #[error("HTTP2HeaderListTooLarge")]
    HTTP2HeaderListTooLarge,
    #[error("HTTP2StreamReset")]
    HTTP2StreamReset,
    #[error("HTTP2GoAway")]
    HTTP2GoAway,
    #[error("HTTP2CompressionError")]
    HTTP2CompressionError,
    #[error("Timeout")]
    Timeout,
    #[error("AbortedBeforeConnecting")]
    AbortedBeforeConnecting,
    #[error("InvalidURL")]
    InvalidURL,
    #[error("ERR_TLS_CERT_ALTNAME_INVALID")]
    ERR_TLS_CERT_ALTNAME_INVALID,
    #[error("ClientAborted")]
    ClientAborted,
    #[error("HTTP2Unsupported")]
    HTTP2Unsupported,
    #[error("ConnectionClosed")]
    ConnectionClosed,
    #[error("DNSResolveFailed")]
    DNSResolveFailed,
    #[error("ConnectionRefused")]
    ConnectionRefused,
    #[error("TooManyRedirects")]
    TooManyRedirects,
    #[error("HTTP3Unsupported")]
    HTTP3Unsupported,
    #[error("ResponseHeadersTooLarge")]
    ResponseHeadersTooLarge,
    #[error("UnrequestedUpgrade")]
    UnrequestedUpgrade,
    #[error("UnexpectedData")]

View on GitHub (pinned to 8c5296ac45)