#31091: ConnectionResetError: [Errno 104] Connection reset by peer with a simple
GET call.
-------------------------------------+-------------------------------------
     Reporter:  Baptiste             |                    Owner:  nobody
  VANDENBORGHT                       |
         Type:  Bug                  |                   Status:  closed
    Component:  HTTP handling        |                  Version:  master
     Severity:  Normal               |               Resolution:  invalid
     Keywords:                       |             Triage Stage:
                                     |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by Baptiste VANDENBORGHT):

 Replying to [comment:1 felixxm]:
 > Thanks for this report, however I cannot reproduce this issue with
 Python 3.6.9 and Django 2.2.8.
 >
 > This can be a side effect of 934acf1126995f6e6ccba5947ec8f7561633c27f
 (ticket #29849), see a commit message:
 > > The combination of those two fixes resulted in yet another problem:
 > > HTTP/1.1 by default allows a client to assume that keep-alive is
 > > supported unless the server disables it via 'Connection: close' -- see
 > > RFC2616 8.1.2.1 for details on persistent connection negotiation. Now
 if
 > > the client receives a response from Django without 'Connection: close'
 > > and immediately sends a new request (on the same tcp connection)
 before
 > > our server closes the tcp connection, it will error out at some point
 > > because the connection does get closed a few milli seconds later.
 >
 > but I don't think that there is anything we can improve in Django.


 Good shot! That's nothing to improve in Django directly, indeed!

 I've just added the header Connection: close and it fixed it (for those
 who may encounter this issue as well)

 Thanks again for your help

-- 
Ticket URL: <https://code.djangoproject.com/ticket/31091#comment:3>
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/067.6afed80b42af6cb13bd2915fcbeeb3da%40djangoproject.com.

Reply via email to