Author tzickel
Recipients christian.heimes, tzickel
Date 2020-04-12.17:28:17
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I am writing this as a bug, as I have an object which implements the buffer protocol but not the __len__.

SSL's recv_into seems to require the buffer object to implement __len__, but this is unlike the socket recv_into which uses the buffer protocol length.

Here is the socket.recv_into implementation:

as you can see, the length is optional, and it not given, it takes it from the buffer protocol length.

But here is SSL recv_into implementation:

if length is not given, it tries to call the __len__ of the object itself (not it's buffer protocol).
Date User Action Args
2020-04-12 17:28:18tzickelsetrecipients: + tzickel, christian.heimes
2020-04-12 17:28:18tzickelsetmessageid: <>
2020-04-12 17:28:17tzickellinkissue40262 messages
2020-04-12 17:28:17tzickelcreate