New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
socket recv returning multiple data types #245
Comments
I tried the following code to reproduce your issue and it consistently returns bytes. What kind of "communication is broken" exactly are you experiencing?
|
as you see, in the second part of the ticket, recv returns empty string after server closed a socket. |
Can you run the code I pasted? It does exactly that: server closes connection after 0.1s timeout, then s2 is empty |
eventlet 0.17.4, did not get errors on your code, here is mine (I was trying to put it into one file, but then there were no errors...) run server, then client, stop server, assertion error shows server:
client:
|
Thank you. Indeed, it deceptively passes when client and server are just two green threads. Error was in |
@temoto what's an oldest supported python version?(I could not find it in the docs) - with 2.5 supported there should be |
That's not a problem, we use few 2.6+ syntax features already. Fix is merged in master 001f31f. |
It must always return bytes. eventlet/eventlet#245
python 3.4 - when using green sockets, most of the time socket.recv is returning bytes, but when
communication is broken, it returns string
returns:
The text was updated successfully, but these errors were encountered: