MCPcopy
hub / github.com/encode/starlette / with_headers

Function with_headers

tests/test_exceptions.py:33–34  ·  view source on GitHub ↗
(request: Request)

Source from the content-addressed store, hash-verified

31
32
33def with_headers(request: Request) -> None:
34 raise HTTPException(status_code=200, headers={"x-potato": "always"})
35
36
37class BadBodyException(HTTPException):

Callers

nothing calls this directly

Calls 1

HTTPExceptionClass · 0.90

Tested by

no test coverage detected