mirror of
https://github.com/dart-lang/sdk
synced 2024-10-14 16:37:43 +00:00
[DAP] Add field showToUser to DebugAdapterException
Bug: https://github.com/dart-lang/sdk/issues/55789 Change-Id: I204672f8e4cf2d073e7640665eaaaa9c8028efe7 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/369720 Commit-Queue: Helin Shiah <helinx@google.com> Reviewed-by: Helin Shiah <helinx@google.com>
This commit is contained in:
parent
2fe6c5d532
commit
150c24f332
4
third_party/pkg/dap/CHANGELOG.md
vendored
4
third_party/pkg/dap/CHANGELOG.md
vendored
|
@ -1,3 +1,7 @@
|
|||
## 1.3.0
|
||||
|
||||
- Add `showToUser` field to `DebugAdapterException` to specify which errors should be shown to users.
|
||||
|
||||
## 1.2.0
|
||||
|
||||
- Added `DartInitializeRequestArguments`, a subclass of `InitializeRequestArguments` that supports a custom flag `supportsDartUris` for informing the debug adapter that the client supports using URIs in places that might usually be file paths (such as `stackTraceRequest`). Setting this flag indicates that the client supports `file:` URIs _and also_ any custom-scheme URIs whose content can be provided by the analysis server from the matching Dart SDK.
|
||||
|
|
9
third_party/pkg/dap/lib/src/exceptions.dart
vendored
9
third_party/pkg/dap/lib/src/exceptions.dart
vendored
|
@ -8,7 +8,10 @@
|
|||
class DebugAdapterException implements Exception {
|
||||
final String message;
|
||||
|
||||
DebugAdapterException(this.message);
|
||||
/// Whether or not to show the error to the user as a notification.
|
||||
final bool showToUser;
|
||||
|
||||
DebugAdapterException(this.message, {this.showToUser = false});
|
||||
|
||||
@override
|
||||
String toString() => 'DebugAdapterException: $message';
|
||||
|
@ -37,12 +40,16 @@ class DebugAdapterInvalidArgumentException implements DebugAdapterException {
|
|||
final Type actualType;
|
||||
final Object? actualValue;
|
||||
|
||||
@override
|
||||
final bool showToUser;
|
||||
|
||||
DebugAdapterInvalidArgumentException({
|
||||
required this.requestName,
|
||||
required this.argumentName,
|
||||
required this.expectedType,
|
||||
required this.actualType,
|
||||
required this.actualValue,
|
||||
this.showToUser = false,
|
||||
});
|
||||
|
||||
@override
|
||||
|
|
2
third_party/pkg/dap/pubspec.yaml
vendored
2
third_party/pkg/dap/pubspec.yaml
vendored
|
@ -1,5 +1,5 @@
|
|||
name: dap
|
||||
version: 1.2.0
|
||||
version: 1.3.0
|
||||
description: >-
|
||||
A package of classes that are generated from the DAP specifications along with
|
||||
their generating code.
|
||||
|
|
Loading…
Reference in a new issue