From 0b6bff2ad060fdb74dd5a494aafaeb6af3d79c10 Mon Sep 17 00:00:00 2001 From: Devon Carew Date: Thu, 31 Jul 2025 15:27:21 -0700 Subject: [PATCH 1/2] update a call to the package:shelf_web_socket webSocketHandler() function --- dwds/CHANGELOG.md | 4 ++++ dwds/lib/src/services/debug_service.dart | 4 ++-- dwds/pubspec.yaml | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/dwds/CHANGELOG.md b/dwds/CHANGELOG.md index d44f1a338..abff4fdf2 100644 --- a/dwds/CHANGELOG.md +++ b/dwds/CHANGELOG.md @@ -1,3 +1,7 @@ +## 24.4.2-wip + +- Update a call to the `package:shelf_web_socket` `webSocketHandler()` function. + ## 24.4.1 - Implemented a WebSocket-based communication protocol that provides essential developer tooling (hot reload, service extensions) when Chrome debugger access is unavailable. - [#2605](https://github.com/dart-lang/webdev/issues/2605) diff --git a/dwds/lib/src/services/debug_service.dart b/dwds/lib/src/services/debug_service.dart index a9c2537e2..17ab88150 100644 --- a/dwds/lib/src/services/debug_service.dart +++ b/dwds/lib/src/services/debug_service.dart @@ -436,11 +436,11 @@ class WebSocketDebugService implements DebugService { } /// Creates the WebSocket handler for incoming connections. - static dynamic _createWebSocketHandler( + static Handler _createWebSocketHandler( ServiceExtensionRegistry serviceExtensionRegistry, WebSocketProxyService webSocketProxyService, ) { - return webSocketHandler((WebSocketChannel webSocket) { + return webSocketHandler((WebSocketChannel webSocket, String? subprotocol) { final responseController = StreamController>(); webSocket.sink.addStream(responseController.stream.map(jsonEncode)); diff --git a/dwds/pubspec.yaml b/dwds/pubspec.yaml index b487f3f98..f61a74ffa 100644 --- a/dwds/pubspec.yaml +++ b/dwds/pubspec.yaml @@ -29,7 +29,7 @@ dependencies: shelf_packages_handler: ^3.0.0 shelf_proxy: ^1.0.4 shelf_static: ^1.1.0 - shelf_web_socket: '>=1.0.0 <3.0.0' + shelf_web_socket: '>=2.0.0 <4.0.0' source_maps: ^0.10.10 stack_trace: ^1.10.0 sse: ^4.1.2 From bcaec1e87b505aa32ce3da16fd7504c106e44a96 Mon Sep 17 00:00:00 2001 From: Devon Carew Date: Thu, 31 Jul 2025 15:32:05 -0700 Subject: [PATCH 2/2] update pubspec version --- dwds/lib/src/version.dart | 2 +- dwds/pubspec.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dwds/lib/src/version.dart b/dwds/lib/src/version.dart index 056d15cd2..4c6b87ade 100644 --- a/dwds/lib/src/version.dart +++ b/dwds/lib/src/version.dart @@ -1,2 +1,2 @@ // Generated code. Do not modify. -const packageVersion = '24.4.1'; +const packageVersion = '24.4.2-wip'; diff --git a/dwds/pubspec.yaml b/dwds/pubspec.yaml index f61a74ffa..e394f75d2 100644 --- a/dwds/pubspec.yaml +++ b/dwds/pubspec.yaml @@ -1,6 +1,6 @@ name: dwds # Every time this changes you need to run `dart run build_runner build`. -version: 24.4.1 +version: 24.4.2-wip description: >- A service that proxies between the Chrome debug protocol and the Dart VM