[issue1767511] SocketServer.DatagramRequestHandler with empty response

2020-11-04 Thread Irit Katriel


Change by Irit Katriel :


--
assignee:  -> docs@python
components: +Documentation
nosy: +docs@python
stage: patch review -> needs patch
versions: +Python 3.10, Python 3.8, Python 3.9 -Python 2.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1767511] SocketServer.DatagramRequestHandler with empty response

2016-02-22 Thread desbma

Changes by desbma :


--
nosy: +desbma

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1767511] SocketServer.DatagramRequestHandler with empty response

2016-02-09 Thread Martin Panter

Martin Panter added the comment:

Sorry that nobody has responded to your patch in almost a decade. :( 
Unfortunately in the meantime the test file seems to have been completely 
rewritten.

For the original problem, I think it would be better if we just documented that 
this is the way it works. Sending an empty response message seems like a 
plausible way to acknowledge handling of a request. This parallels the stream 
handler only shutting down the connection when the request handler has 
finished. Changing this could break compatibility.

Ben: if you’re still interested, can you explain what the problem is on 
Windows? My experiments with Wine on Linux suggest that it can send empty UDP 
responses fine. Is Windows able to send and receive zero-length UDP messages 
with plain sockets? Perhaps this should be a separate bug.

--
nosy: +martin.panter
stage:  -> patch review
title: SocketServer.DatagramRequestHandler -> 
SocketServer.DatagramRequestHandler with empty response

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1767511] SocketServer.DatagramRequestHandler

2012-03-27 Thread Giampaolo Rodola'

Changes by Giampaolo Rodola' g.rod...@gmail.com:


--
nosy: +giampaolo.rodola

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1767511
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1767511] SocketServer.DatagramRequestHandler

2010-06-09 Thread Terry J. Reedy

Changes by Terry J. Reedy tjre...@udel.edu:


--
versions:  -Python 2.5

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1767511
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1767511] SocketServer.DatagramRequestHandler

2008-01-23 Thread Ben Bass

Ben Bass added the comment:

I've just bumped into this issue.  In my opinion the finish() method 
should only do anything if wfile is not empty, i.e:

temp = self.wfile.getvalue()
if temp:
self.socket.sendto(temp, self.client_address)

--
nosy: +bpb

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1767511
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1767511] SocketServer.DatagramRequestHandler

2008-01-23 Thread Christian Heimes

Christian Heimes added the comment:

Can you provide a working patch with a unit test and doc updates?

--
nosy: +tiran
type:  - behavior
versions: +Python 2.6

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1767511
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1767511] SocketServer.DatagramRequestHandler

2008-01-23 Thread Ben Bass

Ben Bass added the comment:

Main issue here (as I see it) is that StreamRequestHandler and 
DatagramRequestHandler should behave in the same way. This is not the 
case in Python 2.5.1 for the case where the handle method does not 
respond to the request socket (e.g. in my case it is forwarding data to 
a different socket).

 While handler methods in StreamRequestHandler need not send any data 
back to the request socket, in DatagramRequestHandlers an attempt will 
be made to send data whether any is available or not. This causes a 
socket hang (for several minutes) on Windows with a '10040 Message too 
long' error.

 By only sending data back to the request if the handler has written to 
wfile, this is avoided, giving the twin fixes of avoiding a nasty 
socket error and providing compatibilty with StreamRequestHandler 
behaviour.

Test has been updated to add tests of handlers which do not respond to 
the request; this causes a hang in Python2.5.1 stock (not sure how to 
avoid this and cleanly fail), test passes with changed SocketServer.

p.s. this is my first patch submission to anything, so go easy :-)

Added file: http://bugs.python.org/file9271/DatagramServer.diff

_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1767511
_
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com