classification
Title: 404 report of SimpleXMLRPCServer is broken
Type: Stage:
Components: Library (Lib) Versions: Python 3.0
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: christian.heimes, gvanrossum
Priority: normal Keywords:

Created on 2007-12-08 16:12 by christian.heimes, last changed 2008-01-06 22:29 by admin. This issue is now closed.

Messages (4)
msg58296 - (view) Author: Christian Heimes (christian.heimes) * (Python committer) Date: 2007-12-08 16:12
Exception happened during processing of request from ('127.0.0.1', 55017)
Traceback (most recent call last):
  File "/home/heimes/dev/python/py3k/Lib/SocketServer.py", line 222, in
handle_request
    self.process_request(request, client_address)
  File "/home/heimes/dev/python/py3k/Lib/SocketServer.py", line 241, in
process_request
    self.finish_request(request, client_address)
  File "/home/heimes/dev/python/py3k/Lib/SocketServer.py", line 254, in
finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/home/heimes/dev/python/py3k/Lib/SocketServer.py", line 522, in
__init__
    self.handle()
  File "/home/heimes/dev/python/py3k/Lib/BaseHTTPServer.py", line 330,
in handle
    self.handle_one_request()
  File "/home/heimes/dev/python/py3k/Lib/BaseHTTPServer.py", line 324,
in handle_one_request
    method()
  File "/home/heimes/dev/python/py3k/Lib/SimpleXMLRPCServer.py", line
430, in do_POST
    self.report_404()
  File "/home/heimes/dev/python/py3k/Lib/SimpleXMLRPCServer.py", line
486, in report_404
    self.wfile.write(response)
  File "/home/heimes/dev/python/py3k/Lib/socket.py", line 220, in write
    return self._sock.send(b)
TypeError: send() argument 1 must be bytes or read-only buffer, not str
----------------------------------------

After I altered the response to bytes:

  File "/home/heimes/dev/python/py3k/Lib/SimpleXMLRPCServer.py", line
430, in do_POST
    self.report_404()
  File "/home/heimes/dev/python/py3k/Lib/SimpleXMLRPCServer.py", line
489, in report_404
    self.connection.shutdown(0)
socket.error: [Errno 107] Transport endpoint is not connected
----------------------------------------
msg58297 - (view) Author: Christian Heimes (christian.heimes) * (Python committer) Date: 2007-12-08 16:13
I disabled test_404 in test_xmlrpc.py r59423
msg58312 - (view) Author: Guido van Rossum (gvanrossum) * (Python committer) Date: 2007-12-09 02:16
Is disabling a test the right solution?
msg58313 - (view) Author: Christian Heimes (christian.heimes) * (Python committer) Date: 2007-12-09 02:20
No, I've fixed the three failing or blocking tests in r59429 and r59434.
History
Date User Action Args
2008-01-06 22:29:44adminsetkeywords: - py3k
versions: Python 3.0
2007-12-09 02:20:02christian.heimessetmessages: + msg58313
2007-12-09 02:16:30gvanrossumsetnosy: + gvanrossum
messages: + msg58312
2007-12-09 01:43:31christian.heimessetstatus: open -> closed
resolution: fixed
2007-12-08 16:13:16christian.heimessetmessages: + msg58297
2007-12-08 16:12:05christian.heimescreate