-
Notifications
You must be signed in to change notification settings - Fork 364
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
Add a better toString to _ClientSocketException #948
Add a better toString to _ClientSocketException #948
Conversation
Also explain how to catch `SocketException`. Fixes dart-lang#930
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to bump to a -wip
version in the pubspec. May also be worth a changelog entry.
pkgs/http/lib/src/client.dart
Outdated
@@ -25,6 +25,10 @@ import 'streamed_response.dart'; | |||
/// [http.head], [http.get], [http.post], [http.put], [http.patch], or | |||
/// [http.delete] instead. | |||
/// | |||
/// All methods will emit a [ClientException] if there is a transport-level | |||
/// failure when communication with the server, e.g., if the server could not |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
pkgs/http/lib/src/io_client.dart
Outdated
/// | ||
/// If there is a socket-level failure when communicating with the server | ||
/// (e.g. if the server could not be reached), [IOClient] will emit a | ||
/// [ClientException] that is also implements [SocketException]. This allows |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/// [ClientException] that is also implements [SocketException]. This allows | |
/// [ClientException] that also implements [SocketException]. This allows |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
Done. |
Also explain how to catch
SocketException
.Fixes #930
Contribution guidelines:
dart format
.(note that many Dart repos have a weekly cadence for reviewing PRs - please allow for some latency before initial review feedback)