Repository navigation
[v9.4.1] - 2026-11-09
A patch release: a declared response model no longer turns a handler that
writes its own body into a 500, and a response with no body stays empty.
Fixed
response_model=(and an inferred return annotation) validates and
serializes the structured channel only: a returned value, orresp.media.
A handler that assignsresp.content,resp.text,resp.html, a file, or
a stream sends that body unchanged. The model stays on the OpenAPI
operation and on the MCP tooloutputSchema.response_model=Falsestill
removes it from both. Previously those routes 500'd unless they opted out,
and opting out also droppedoutputSchema.- A response that never sets a body is empty. It is no longer
content-negotiated into JSONnull. Assignresp.media = Noneto send a
JSON null on purpose. - MCP tool descriptions taken from a docstring use the prose above a line
that is exactly---. The OpenAPI YAML below that line is left out. A
docstring that is only that YAML uses its operationsummary, or is empty
when it has none. An explicitdescription=is kept as given, and OpenAPI
still reads the YAML block.