Skip to content
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

fix AsyncClient::wait unexpected return after success reconnect #1407

Merged
merged 4 commits into from
Dec 14, 2024

Conversation

arkuzo
Copy link
Contributor

@arkuzo arkuzo commented Nov 19, 2024

AsyncClient::wait use sleep(1) call to wait to start reconnect task. Sometimes reconnect is faster then 1 second, and wait returns while connection to server is established.

Added one check to method to avoid this situation

AsyncClient::wait use sleep(1) call to wait to start reconnect task.
Sometimes reconnect is faster then 1 second, and wait returns while connection to server is established.

Added one check to avoid this situation
@miguelgrinberg
Copy link
Owner

Makes sense, thanks!

Could I ask you to apply a similar fix to the synchronous client?

@arkuzo
Copy link
Contributor Author

arkuzo commented Nov 19, 2024

Could I ask you to apply a similar fix to the synchronous client?

Applied

@miguelgrinberg miguelgrinberg merged commit 78d1124 into miguelgrinberg:main Dec 14, 2024
20 of 22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants