Quiver.Error.H3Codes (quiver v0.3.0)

Copy Markdown View Source

HTTP/3 error code constants (RFC 9114 Section 8.1) and decode helper. Mirrors lib/quiver/conn/http2/errors.ex for h2.

Summary

Functions

Decode an H3 error code to its atom name, or {:unknown, code} if not in the table.

All known H3 error codes as a {code, atom} list.

Types

error_code()

@type error_code() ::
  :h3_no_error
  | :h3_general_protocol_error
  | :h3_internal_error
  | :h3_stream_creation_error
  | :h3_closed_critical_stream
  | :h3_frame_unexpected
  | :h3_frame_error
  | :h3_excessive_load
  | :h3_id_error
  | :h3_settings_error
  | :h3_missing_settings
  | :h3_request_rejected
  | :h3_request_cancelled
  | :h3_request_incomplete
  | :h3_message_error
  | :h3_connect_error
  | :h3_version_fallback

Functions

decode(code)

@spec decode(non_neg_integer()) :: error_code() | {:unknown, non_neg_integer()}

Decode an H3 error code to its atom name, or {:unknown, code} if not in the table.

list()

@spec list() :: [{non_neg_integer(), error_code()}]

All known H3 error codes as a {code, atom} list.