Expand description
One error type for every handler. Spec section 12: the web side shows friendly error pages, errors inside htmx partials show inline, and a Postgres outage is a 503 page.
AppError::into_response only records what went wrong (an ErrorInfo extension); the
error_pages middleware, which can see whether the request came from htmx, turns that
into either a full page or an inline fragment.
Structs§
- Error
Info - What went wrong, attached to an error response for
error_pagesto render.
Enums§
Functions§
- error_
pages - Renders
ErrorInforesponses as a full page, or as an inline fragment for htmx. - is_
unavailable - Connection-level failures mean Postgres is down or unreachable: a 503, not a 500.
- not_
found - The router’s fallback: unknown paths get the friendly 404.