[issue33307] socket.send() fails to send large amount of bytes

Kaulkwappe report at bugs.python.org
Wed Apr 18 08:57:22 EDT 2018


Kaulkwappe <bugs.python.org at prvy.eu> added the comment:

Sorry for the misunderstanding, here is the complete example:

socket.setblocking(0)

try:
	buffer = socket.recv()

	if not buffer:
		break

except OSError:
	bytes_sent = socket.send(b'a' * 32 * 1024 * 1024)

In this case the socket is ready for sending data and should return the bytes that were actually sent. But when sending a large amount of bytes it every time fails with SSLWantWriteError exception.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue33307>
_______________________________________


More information about the Python-bugs-list mailing list