-
Notifications
You must be signed in to change notification settings - Fork 319
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
ssl.SSLWantReadError: The operation did not complete (read) #87
Comments
This looks like https://bugs.python.org/issue12343 . Try replacing the
|
If its working would you like to put in a pull request? |
Unfortunately I have not been able to test any of this as I have not run into this problem myself. There also seems to be very little documentation about this issue, and one of the few comments I've seen says select() is not going to fire when the data does arrive, so I'm hesitant to commit code I can't verify works. I have some ideas on a test setup to try and reproduce this but have not found the time to set it up. |
This project has been really helpful. Ran into a similar problem as in this thread. The SSL websocket was closing when a large amount of data was sent. I found a solution. I got rid of the else statement at line 341. Then the while loop sending data retries until it is successful rather than closing the socket. |
I don't like blindly ignoring all errors as on an unclean close the socket is going to hang and stick around forever and block all other clients while it does it. What is the exact exception thrown? Adding it to the list of try-again exceptions would be better. |
I'm using OkHttpClient on Android to connect to my websocket server. When my app establishes a connection, I send a message. Shorter messages don't have an issue, but for longer messages I'm getting an exception. The message I'm testing with is 14819 characters long in JSON format, but I've tested some smaller messages and the exception starts appearing when it's around 4315 characters long. The culprit is this line.
Here's the stack trace:
I don't know the protocol well so it's hard for me to tell whether it's the fault of this library or OkHttpClient or maybe I'm just doing something wrong. The only thing I've tried is increasing the
16384
to a higher number but it didn't help.The text was updated successfully, but these errors were encountered: