This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author neologix
Recipients exarkun, mdcowles, neologix, pitrou
Date 2010-04-26.15:22:37
SpamBayes Score 1.7207519e-06
Marked as misclassified No
Message-id <1272295358.91.0.610259764452.issue8493@psf.upfronthosting.co.za>
In-reply-to
Content
> I don't see any evidence in support of this statement. 

From Microfost Windows' documentation:

"The parameter writefds identifies the sockets that are to be checked for writability. If a socket is processing a connect call (nonblocking), a socket is writeable if the connection establishment successfully completes. If the socket is not processing a connect call, writability means a send, sendto, or WSASendto are guaranteed to succeed. However, they can block on a blocking socket if the len parameter exceeds the amount of outgoing system buffer space available. It is not specified how long these guarantees can be assumed to be valid, particularly in a multithreaded environment."

For the Linux kernel, a few years ago a socket would be returned as writable if it had a fixed amount of send socket buffer queue available, so if you send more than is available at that time, you're either going to block, or get an error (now the threshold is 1/2 of the used buffer space, but this doesn't change the problem).
That's why I said it's not reliable.

> Did you notice that the FreeBSD thread you referenced is:

  * 6 years old
  * about UDP

So ? 

> It's not obvious to me that it's actually relevant here.

I'm not saying that it's the source of the problem, I'm just saying that there's a record of send() calls failing on lack of socket buffers, on blocking sockets.
History
Date User Action Args
2010-04-26 15:22:38neologixsetrecipients: + neologix, mdcowles, exarkun, pitrou
2010-04-26 15:22:38neologixsetmessageid: <1272295358.91.0.610259764452.issue8493@psf.upfronthosting.co.za>
2010-04-26 15:22:37neologixlinkissue8493 messages
2010-04-26 15:22:37neologixcreate