fix(omp): keep transcript replay responsive (#7948)

* fix(omp): keep transcript replay responsive

Index transcript branches in bounded asynchronous chunks and retain payloads only for the active chain, so large histories do not block unrelated daemon requests.

* test(omp): enforce responsive history replay in CI

Use a smaller structured transcript and a short selected chain to expose whole-file parsing without making large-output GC part of the CI gate. Disable unrelated provider discovery and route the regression through the existing integration job.

* test(ci): include OMP replay in the routing contract
This commit is contained in:
Mohamed Boudra
2026-10-27 09:56:27 +07:00
committed by GitHub
parent fc0cbbb323
commit 8d971876bf
6 changed files with 302 additions and 26 deletions
+2 -2
View File
@@ -483,14 +483,14 @@ test("Windows units and integration run independently with complete routed cover
assert.equal(scripts.test, "npm run test:unit && npm run test:integration");
assert.equal(scripts["test:unit"], 'vitest run --fileParallelism --exclude "**/*.e2e.test.ts"');
const invocations = scripts["test:integration"].split(" && ");
// Each vitest start costs about half a minute on Windows, so the four
// Each vitest start costs about half a minute on Windows, so the
// name-filtered files share one invocation and one combined filter.
assert.equal(invocations.length, 2);
assert.ok(invocations.every((command) => command.startsWith("vitest run --maxWorkers=1 ")));
assert.doesNotMatch(invocations[0], / -t /);
assert.equal(
invocations[1],
'vitest run --maxWorkers=1 src/server/daemon-e2e/git-operations.e2e.test.ts src/server/session.create-agent-worktree-autoarchive.e2e.test.ts src/server/agent/providers/opencode-bridge.local.e2e.test.ts src/server/daemon-e2e/relay-transport.e2e.test.ts -t "merges into|creates a worktree and auto-archives both|versioned runtime|oversized attachments|connected hosts|password-protected daemon refuses"',
'vitest run --maxWorkers=1 src/server/agent/providers/omp/history.e2e.test.ts src/server/daemon-e2e/git-operations.e2e.test.ts src/server/session.create-agent-worktree-autoarchive.e2e.test.ts src/server/agent/providers/opencode-bridge.local.e2e.test.ts src/server/daemon-e2e/relay-transport.e2e.test.ts -t "merges into|creates a worktree and auto-archives both|versioned runtime|oversized attachments|connected hosts|password-protected daemon refuses|replays selected OMP history"',
);
const serverConfig = readFileSync(new URL("packages/server/vitest.config.ts", repoRoot), "utf8");
assert.doesNotMatch(serverConfig, /maxWorkers/);