]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-35017, socketserver: don't accept request after shutdown (GH-9952)
authorDenis Ledoux <be.ledoux.denis@gmail.com>
Fri, 26 Oct 2018 13:46:17 +0000 (15:46 +0200)
committerVictor Stinner <vstinner@redhat.com>
Fri, 26 Oct 2018 13:46:17 +0000 (15:46 +0200)
commit10cb3760e8631a27f5db1e51b05494e29306c671
tree659467c2c67072a1e6b83bc0d994f47ed8b727f3
parent25a525bf5a9c630a992d2048d863841481004465
bpo-35017, socketserver: don't accept request after shutdown (GH-9952)

Prior to this revision, after the shutdown of a `BaseServer`,
the server accepted a last single request
if it was sent between the server socket polling
and the polling timeout.

This can be problematic for instance for a server restart
for which you do not want to interrupt the service,
by not closing the listening socket during the restart.
One request failed because of this behavior.

Note that only one request failed,
following requests were not accepted, as expected.
Lib/socketserver.py
Misc/NEWS.d/next/Library/2018-10-26-00-11-21.bpo-35017.6Ez4Cv.rst [new file with mode: 0644]