mirror of
https://github.com/stablyai/orca.git
synced 2026-09-29 08:03:20 +00:00
test: diagnose replay-suppressed input during SSH pane restore
This commit is contained in:
@@ -33,6 +33,9 @@ export function installPtyInputForward(session: ConnectPanePtySession): void {
|
||||
// engage the guard via replayIntoTerminal; here we drop everything
|
||||
// xterm emits while the guard is active. See replay-guard.ts.
|
||||
if (isPaneReplaying(session.deps.replayingPanesRef, session.pane.id)) {
|
||||
const dataset = session.pane.container.dataset
|
||||
dataset.e2eReplayDroppedInput = ((dataset.e2eReplayDroppedInput ?? '') + data).slice(-512)
|
||||
dataset.e2eReplayDropCount = String(Number(dataset.e2eReplayDropCount ?? '0') + 1)
|
||||
return
|
||||
}
|
||||
const currentPtyId = session.transport.getPtyId()
|
||||
|
||||
@@ -144,6 +144,15 @@ test.describe('five SSH panes under simultaneous output', () => {
|
||||
})
|
||||
throw error
|
||||
} finally {
|
||||
const replayDrops = await orcaPage.evaluate((tabId) => {
|
||||
const manager = window.__paneManagers!.get(tabId)!
|
||||
return manager.getPanes().map((pane) => ({
|
||||
ptyId: pane.container.dataset.ptyId,
|
||||
droppedInput: pane.container.dataset.e2eReplayDroppedInput ?? '',
|
||||
dropCount: pane.container.dataset.e2eReplayDropCount ?? '0'
|
||||
}))
|
||||
}, tabId)
|
||||
console.log('[five-pane-replay-drops]', JSON.stringify({ round, index, replayDrops }))
|
||||
await inputTrace.evaluate((trace) => trace.dispose())
|
||||
await inputTrace.dispose()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user