mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-03 14:09:42 +02:00
fix(terminal): bound live xterm backpressure
This commit is contained in:
@@ -225,10 +225,11 @@ describe('OpenCode session initial resize', () => {
|
||||
await route.continue();
|
||||
});
|
||||
|
||||
// Dispatch the needsRefresh event directly on the EventSource
|
||||
// (this is how the server sends SSE events — as named events)
|
||||
// Exercise the SSE fallback path. While WebSocket owns terminal I/O these
|
||||
// duplicate SSE terminal events are intentionally ignored.
|
||||
await page.evaluate((sid: string) => {
|
||||
const app = (window as unknown as { app: { eventSource: EventSource } }).app;
|
||||
const app = (window as unknown as { app: { eventSource: EventSource; _disconnectWs: () => void } }).app;
|
||||
app._disconnectWs();
|
||||
if (app.eventSource) {
|
||||
const event = new MessageEvent('session:needsRefresh', {
|
||||
data: JSON.stringify({ id: sid }),
|
||||
|
||||
Reference in New Issue
Block a user