Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5771ee5

Browse files
authored
Fix serialization of HotRestartRequest in AppConnection (#2792)
Fix serialization issue of HotRestartRequest that was causing problems when rolling webdev in g3. Related to https://buganizer.corp.google.com/issues/484292194
1 parent c797cb8 commit 5771ee5

3 files changed

Lines changed: 3 additions & 2 deletions

File tree

dwds/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
a new connection request.
1010
- Add sourcemap logic fixes to DDC Library Bundle + build_runner execution scheme.
1111
- Update pathing logic for Windows and the DDC Library Bundle module system.
12+
- Fix serialization of `HotRestartRequest` in `AppConnection`.
1213

1314
## 27.0.0
1415
- Remove `package:built_value`, `package:built_value_generator`, and `package:built_collection` dependencies.

dwds/lib/src/connections/app_connection.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,5 +52,5 @@ class AppConnection {
5252
/// In this case, there's no need to block main execution until the debugger
5353
/// resends breakpoints.
5454
void hotRestart(HotRestartRequest request) =>
55-
_connection.sink.add(jsonEncode(request.toJson()));
55+
_connection.sink.add(jsonEncode(['HotRestartRequest', request.toJson()]));
5656
}

dwds/test/integration/fixtures/context.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -764,7 +764,7 @@ class TestContext {
764764
/// - Entrypoints (served): web/main.dart -> main
765765
/// - Entrypoints (nested): test/hello_world/main.dart -> hello_world/main
766766
/// - Library files: lib/path/to/some_file.dart
767-
/// -> packages/<package>/path/to/some_file
767+
/// -> `packages/<package>/path/to/some_file`
768768
void _updateReloadedSources(String absolutePath) {
769769
final relativePath = p.relative(
770770
absolutePath,

0 commit comments

Comments
 (0)