[issue16434] SocketServer call shutdown in the wrong way
Erik Günther
report at bugs.python.org
Thu Nov 8 13:33:10 CET 2012
New submission from Erik Günther:
I have a small development WSGI-server using PythonPaste and when shutting it down I somtimes get the following error on one or two threads:
-----------------------8<-----------------------------------
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 551, in __bootstrap_inner
self.run()
File "/usr/lib/python2.7/threading.py", line 504, in run
self.__target(*self.__args, **self.__kwargs)
File "/usr/lib/python2.7/SocketServer.py", line 586, in process_request_thread
self.shutdown_request(request)
File "/usr/lib/python2.7/SocketServer.py", line 459, in shutdown_request
request.shutdown(socket.SHUT_WR)
TypeError: shutdown() takes exactly 0 arguments (1 given)
--------------------->8-------------------------------------
/usr/lib/python2.7/SocketServer.py: ------------8<-----------
def shutdown_request(self, request):
"""Called to shutdown and close an individual request."""
try:
#explicitly shutdown. socket.close() merely releases
#the socket and waits for GC to perform the actual close.
request.shutdown(socket.SHUT_WR)
except socket.error:
pass #some platforms may raise ENOTCONN here
self.close_request(request)
----------------->8------------------------------------------
So I recon its a bug...
----------
messages: 175152
nosy: Erik.Günther
priority: normal
severity: normal
status: open
title: SocketServer call shutdown in the wrong way
type: crash
versions: Python 2.7
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16434>
_______________________________________
More information about the Python-bugs-list
mailing list