#33738: ASGI http.disconnect not handled on requests with body.
--------------------------------+------------------------------------
Reporter: Carlton Gibson | Owner: nobody
Type: Bug | Status: new
Component: HTTP handling | Version: 4.0
Severity: Normal | Resolution:
Keywords: ASGI | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
--------------------------------+------------------------------------
Comment (by Jeremy Lainé):
Hi Carlton, I'm not sure if the description of this bug is 100% accurate.
From what I can see, `http.disconnect` is indeed only handled while
receiving the body, so we're not going to handle this event once the
(potentially empty) body is fully received. Adding `"more_body": False` to
your proposed test makes it pass.
I had a look for how Starlette handles `http.disconnect`, and from what I
understand the pattern seems to rely on `anyio.create_taskgroup()` to tear
down request processing if an `http.disconnect` is received.
--
Ticket URL: <https://code.djangoproject.com/ticket/33738#comment:6>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/010701836f61c055-6dd12a7b-d165-446c-95c3-369a8210900c-000000%40eu-central-1.amazonses.com.