From e8225014d1c465511fc535a86cda1e33dbb2a64c Mon Sep 17 00:00:00 2001 From: divybot Date: Mon, 27 Apr 2026 22:47:15 +0530 Subject: [PATCH 1/4] fix(ext/node): align inspector WebSocket URL with Node.js format (ws://host:port/UUID) Enables tests/node_compat/runner/suite/test/parallel/test-inspector-invalid-protocol.js Co-authored-by: Divy Srivastava --- .claude/scheduled_tasks.lock | 1 + libs/inspector_server/lib.rs | 19 ++++++++++++++----- tests/node_compat/config.jsonc | 2 ++ 3 files changed, 17 insertions(+), 5 deletions(-) create mode 100644 .claude/scheduled_tasks.lock diff --git a/.claude/scheduled_tasks.lock b/.claude/scheduled_tasks.lock new file mode 100644 index 00000000000000..34b7394181a791 --- /dev/null +++ b/.claude/scheduled_tasks.lock @@ -0,0 +1 @@ +{"sessionId":"0f811d0c-b373-44a9-9bee-13656988af4a","pid":94788,"procStart":"Mon Apr 27 16:13:58 2026","acquiredAt":1777308276365} \ No newline at end of file diff --git a/libs/inspector_server/lib.rs b/libs/inspector_server/lib.rs index 77750a67a44d94..26d28a1a711512 100644 --- a/libs/inspector_server/lib.rs +++ b/libs/inspector_server/lib.rs @@ -258,10 +258,13 @@ fn handle_ws_request( let (parts, body) = req.into_parts(); let req = http::Request::from_parts(parts, ()); - let maybe_uuid = req - .uri() - .path() + // Accept both /UUID (Node.js-compatible format) and /ws/UUID (legacy + // format) so existing clients keep working while new ones can use the + // shorter Node.js-style URL. + let path = req.uri().path(); + let maybe_uuid = path .strip_prefix("/ws/") + .or_else(|| path.strip_prefix('/')) .and_then(|s| Uuid::parse_str(s).ok()); let Some(uuid) = maybe_uuid else { @@ -581,6 +584,12 @@ async fn server( (&http::Method::GET, "/json/list") if publish_uid.http => { handle_json_request(Rc::clone(&inspector_map), host) } + // Node.js-compatible "/UUID" path for the WebSocket session. + (&http::Method::GET, path) + if Uuid::parse_str(path.trim_start_matches('/')).is_ok() => + { + handle_ws_request(req, Rc::clone(&inspector_map)) + } _ => http::Response::builder() .status(http::StatusCode::NOT_FOUND) .body(Box::new(http_body_util::Full::new(Bytes::from( @@ -750,12 +759,12 @@ impl InspectorInfo { } pub fn get_websocket_debugger_url(&self, host: &str) -> String { - format!("ws://{}/ws/{}", host, &self.uuid) + format!("ws://{}/{}", host, &self.uuid) } fn get_frontend_url(&self, host: &str) -> String { format!( - "devtools://devtools/bundled/js_app.html?ws={}/ws/{}&experiments=true&v8only=true", + "devtools://devtools/bundled/js_app.html?ws={}/{}&experiments=true&v8only=true", host, &self.uuid ) } diff --git a/tests/node_compat/config.jsonc b/tests/node_compat/config.jsonc index 5da0faa75616b6..e15be6890a0283 100644 --- a/tests/node_compat/config.jsonc +++ b/tests/node_compat/config.jsonc @@ -1853,6 +1853,8 @@ // "parallel/test-inspect-address-in-use.js": {}, // "parallel/test-inspector-inspect-brk-node.js": {}, // "parallel/test-inspector-invalid-args.js": {}, + "parallel/test-inspector-invalid-protocol.js": {}, + "parallel/test-inspector-close-worker.js": {}, // TODO(bartlomieju): times out From 5d309e9d5edd588c8e9e4d290f7cfafba27880a2 Mon Sep 17 00:00:00 2001 From: divybot Date: Tue, 28 Apr 2026 00:53:55 +0530 Subject: [PATCH 2/4] chore: remove accidentally committed scheduled_tasks.lock Co-authored-by: Divy Srivastava --- .claude/scheduled_tasks.lock | 1 - 1 file changed, 1 deletion(-) delete mode 100644 .claude/scheduled_tasks.lock diff --git a/.claude/scheduled_tasks.lock b/.claude/scheduled_tasks.lock deleted file mode 100644 index 34b7394181a791..00000000000000 --- a/.claude/scheduled_tasks.lock +++ /dev/null @@ -1 +0,0 @@ -{"sessionId":"0f811d0c-b373-44a9-9bee-13656988af4a","pid":94788,"procStart":"Mon Apr 27 16:13:58 2026","acquiredAt":1777308276365} \ No newline at end of file From 09ba2af055ddeded2b1049329463e312bae2963e Mon Sep 17 00:00:00 2001 From: divybot Date: Tue, 28 Apr 2026 15:33:47 +0530 Subject: [PATCH 3/4] chore: retrigger CI Linux-x86_64 integration shard 0 hit a sysroot-decompress flake during the "Set up incremental LTO and sysroot build" step (exit 8). Re-running to clear the infra-side failure; no source changes. Co-authored-by: Divy Srivastava From 1bcb67b108c5041fb6979fb0076cae9f36a2e34a Mon Sep 17 00:00:00 2001 From: divybot Date: Tue, 28 Apr 2026 16:01:16 +0530 Subject: [PATCH 4/4] chore: drop stray blank line introduced by rebase MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Match main"'s layout: invalid-args (commented) → invalid-protocol → close-worker with no blank line between the two active entries. Co-authored-by: Divy Srivastava --- tests/node_compat/config.jsonc | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/node_compat/config.jsonc b/tests/node_compat/config.jsonc index e15be6890a0283..5152baf3c02dd9 100644 --- a/tests/node_compat/config.jsonc +++ b/tests/node_compat/config.jsonc @@ -1854,7 +1854,6 @@ // "parallel/test-inspector-inspect-brk-node.js": {}, // "parallel/test-inspector-invalid-args.js": {}, "parallel/test-inspector-invalid-protocol.js": {}, - "parallel/test-inspector-close-worker.js": {}, // TODO(bartlomieju): times out