Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

ready completes with exceptions and is therefore a breaking change #1638

Closed
hacker1024 opened this issue May 7, 2023 · 2 comments · Fixed by dart-archive/web_socket_channel#272

Comments

@hacker1024
Copy link

dart-archive/web_socket_channel#240 added the ready property, which completes when the connection is established. It also completes with errors when the connection fails. This results in uncaught exceptions when ready is not being handled.

This breaks semantic versioning, and should be at the very least be explained in the v2.3.0 changelog. I think it should also be mentioned in the documentation, as the stack traces do not always make it easy to work out where these uncaught exceptions can be caught.

@matiasmarcodelpont
Copy link

I think I'm having this error. I'm calling IOWebSocketChannel.connect inside a try catch, but when the connection fails, the error isn't being catched. I can't find a way to handle this error

@brianquinlan
Copy link
Collaborator

Sorry for not managing this change better. I plan on updating the documentation in dart-archive/web_socket_channel#272

Please feel free to comment if something could be more clear.

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants