I've been wondering... Uvicorn is the only ASGI server that sends http.response.start, and then processes the body. The problem with this approach, is that the successful response may be a lie, if there's an error when processing the body.
And... I was thinking about changing the behavior on Uvicorn.
I was wondering, why do we allow http.response.start to be sent before the body?
The idea was to emulate the WSGI behaviour, where you can begin the HTTP response before you then start streaming the body contents (start_response versus the contents of an iterator).
I've been wondering... Uvicorn is the only ASGI server that sends
http.response.start
, and then processes the body. The problem with this approach, is that the successful response may be a lie, if there's an error when processing the body.And... I was thinking about changing the behavior on Uvicorn.
I was wondering, why do we allow
http.response.start
to be sent before the body?