From 36b860e322454df62ebf5309018590b596e6b913 Mon Sep 17 00:00:00 2001 From: CoderLuii Date: Mon, 1 Jun 2026 13:56:51 -0400 Subject: [PATCH] fix: preserve WebSocket frame type in plugin proxy (#594) * fix: preserve WebSocket frame type in plugin proxy The plugin WebSocket proxy relays all messages as binary frames regardless of the original frame type. This causes text-based ready messages to be forwarded as binary, so the browser never processes them and plugin UIs (like web-terminal) show a spinner indefinitely. Pass the isBinary flag through in both relay directions so the original frame type is preserved. Fixes CoderLuii/HolyClaude#11 * fix(plugins): preserve websocket frame type in proxy Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus --------- Co-authored-by: Sisyphus --- .../websocket/services/plugin-websocket-proxy.service.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/server/modules/websocket/services/plugin-websocket-proxy.service.ts b/server/modules/websocket/services/plugin-websocket-proxy.service.ts index 491fd540..34e86ac6 100644 --- a/server/modules/websocket/services/plugin-websocket-proxy.service.ts +++ b/server/modules/websocket/services/plugin-websocket-proxy.service.ts @@ -26,15 +26,15 @@ export function handlePluginWsProxy( console.log(`[Plugins] WS proxy connected to "${pluginName}" on port ${port}`); }); - upstream.on('message', (data) => { + upstream.on('message', (data, isBinary) => { if (clientWs.readyState === WebSocket.OPEN) { - clientWs.send(data); + clientWs.send(data, { binary: isBinary }); } }); - clientWs.on('message', (data) => { + clientWs.on('message', (data, isBinary) => { if (upstream.readyState === WebSocket.OPEN) { - upstream.send(data); + upstream.send(data, { binary: isBinary }); } });