You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ws: public client/server fixture receives unexpected HTTP 426 response #10888
A clean public-entry ws@8.21.1 client/server fixture compiles on current main (47ade47327) but the client fails with:
Error: Unexpected server response: 426
This is the current ws blocker found while re-testing #10797. The issue's original post-handshake Cannot read properties of undefined (reading 'destroy') failure does not reproduce.
Reproduction shape
Install ws@8.21.1.
Add ws to perry.compilePackages.
Import { WebSocketServer, WebSocket } from the public ws entry point.
Start a local WebSocketServer and connect to it with a public WebSocket client.
Compile and run with Perry.
No partial-codegen flag or internal package import is used.
Expected
The local WebSocket upgrade succeeds and the server emits its connection event, as under Node.
Actual
The client reports HTTP 426 instead of completing the WebSocket upgrade.
Provenance
Split from #10797 after re-establishing the package probe through its normal public entry point. See the re-test details.
Fixed in v0.5.1633 (merge train 253, 0fa3915293) by #10899 — fix(http): preserve upgrades over custom connections.
An HTTP upgrade request using a custom createConnection socket lost Connection: Upgrade, so the ws handshake saw an ordinary request and the server answered 426 Upgrade Required. Perry now preserves the upgrade and emits the request's upgrade event.
Verified by running crates/perry/tests/issue_10888_create_connection_upgrade.rs against the landed tree: 2 passed, 0 failed.
Activity
fix(http): preserve upgrades over custom connections (#10888)
proggeramlug commentedon Sep 21, 2026
Fixed in v0.5.1633 (merge train 253,
0fa3915293) by #10899 —fix(http): preserve upgrades over custom connections.An HTTP upgrade request using a custom
createConnectionsocket lostConnection: Upgrade, so thewshandshake saw an ordinary request and the server answered426 Upgrade Required. Perry now preserves the upgrade and emits the request'supgradeevent.Verified by running
crates/perry/tests/issue_10888_create_connection_upgrade.rsagainst the landed tree: 2 passed, 0 failed.