fix(ci): #540 landing fixes

Move the nightly cron from 03:17 to 03:23 UTC. GitHub sends scheduled-run
failure notices to whoever last modified the cron line, and after the merge
that is the contributor, so a maintainer commit has to touch it. The
docs below give no clock time, so they cannot drift from the cron.

Drop the "Keep the failure artifacts" step and the blank line before it.
No browser test writes test-results/ or screenshots-echo-diag/ (only the
ignore files name them), and if-no-files-found: ignore made the step upload
nothing without a word. The run log already carries the failure output.

Reword the workflow header. Drop the claim that the skipped suite let two
semantically conflicting PRs merge green: that incident came from
test/mobile/keyboard.test.ts, which this job does not run. Correct the
codex-predictive-echo note: the test uses a fake key in a throwaway
CODEX_HOME and skips itself when codex is missing, so it needs a codex
binary, not an authenticated one.

opencode-resize: record WebSocket resize frames under the socket's own URL
instead of appending '#' + the session id. The URL already carries
/ws/sessions/<id>/terminal, and the suffix let toContain(sessionId) pass for
a resize sent on any session's socket, the bug this test exists to catch.

Reduce the six session-id extractions (opencode-resize and perf-browser) to
data.data?.session?.id. POST /api/sessions always answers in the
{ success, data: { session } } envelope, and the dead fallbacks are what
hid the original breakage.

split-pane-terminal: restore the browser config's 60 s test timeout (the
added 20000 ms override tightened it), and replace the comment that blamed
Codeman's post-create clear. Under vitest the session is an echo PTY, so
that clear comes back as text; the real fix is useMux:false, since a plain
prompt otherwise goes through tmux send-keys, which test mode no-ops.

CLAUDE.md: the CI note now says the gate excludes the Playwright tests in
BROWSER_TEST_GLOBS instead of a stale count of 14, and names
browser-suite.yml; the Testing warning says the browser suite runs nightly.
CONTRIBUTING.md gets the same one-line pointer under Tests.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Codeman maintainer
2026-10-09 05:13:06 +02:00
parent 4502bfe8a9
commit 02c65e988a
6 changed files with 21 additions and 32 deletions
+6 -8
View File
@@ -119,13 +119,12 @@ describe('OpenCode session initial resize', () => {
ws.on('framesent', (frame) => {
try {
const msg = JSON.parse(String(frame.payload));
if (msg.t === 'z') resizeCalls.push({ url: ws.url() + '#' + sessionIdForWs, cols: msg.c, rows: msg.r });
if (msg.t === 'z') resizeCalls.push({ url: ws.url(), cols: msg.c, rows: msg.r });
} catch {
/* not JSON */
}
});
});
let sessionIdForWs = '';
await page.route('**/api/sessions/*/resize', async (route) => {
const request = route.request();
const body = request.postDataJSON();
@@ -147,11 +146,10 @@ describe('OpenCode session initial resize', () => {
});
const data = await res.json();
// POST /api/sessions answers in the { success, data: { session } } envelope.
return data.data?.session?.id ?? data.id ?? data.session?.id;
return data.data?.session?.id;
});
expect(sessionId).toBeTruthy();
sessionIdForWs = sessionId;
// Call selectSession (which is what runOpenCode does after fix)
await page.evaluate(async (sid: string) => {
@@ -194,7 +192,7 @@ describe('OpenCode session initial resize', () => {
});
const data = await res.json();
// POST /api/sessions answers in the { success, data: { session } } envelope.
return data.data?.session?.id ?? data.id ?? data.session?.id;
return data.data?.session?.id;
});
expect(sessionId).toBeTruthy();
@@ -246,7 +244,7 @@ describe('OpenCode session initial resize', () => {
});
const data = await res.json();
// POST /api/sessions answers in the { success, data: { session } } envelope.
return data.data?.session?.id ?? data.id ?? data.session?.id;
return data.data?.session?.id;
});
expect(sessionId).toBeTruthy();
@@ -331,7 +329,7 @@ describe('OpenCode close modal text', () => {
});
const data = await res.json();
// POST /api/sessions answers in the { success, data: { session } } envelope.
return data.data?.session?.id ?? data.id ?? data.session?.id;
return data.data?.session?.id;
});
expect(sessionId).toBeTruthy();
@@ -374,7 +372,7 @@ describe('OpenCode close modal text', () => {
});
const data = await res.json();
// POST /api/sessions answers in the { success, data: { session } } envelope.
return data.data?.session?.id ?? data.id ?? data.session?.id;
return data.data?.session?.id;
});
expect(sessionId).toBeTruthy();
+1 -1
View File
@@ -70,7 +70,7 @@ async function createSession(page: Page, name: string): Promise<string> {
});
const data = await res.json();
// POST /api/sessions answers in the { success, data: { session } } envelope.
return data.data?.session?.id ?? data.id ?? data.session?.id;
return data.data?.session?.id;
}, name);
return result as string;
}
+4 -4
View File
@@ -113,9 +113,9 @@ describe('TerminalTile in a real browser', () => {
// own startup can race an early write and, on this box, a startup
// script issues a `clear` that erases scrollback (modern ncurses
// `clear` emits \x1b[3J) if the input lands before the shell is ready.
// Codeman itself writes `clear` into a NEW shell session ~100ms after
// creating it, which can erase an early marker, so re-send until the
// marker is present in the capture rather than writing once.
// Send with useMux:false: a plain prompt otherwise goes out through
// tmux send-keys, which test mode no-ops, so the marker never reached
// the PTY. Re-sending until the capture shows it is just belt and braces.
const deadline = Date.now() + 8000;
for (;;) {
await fetch(`/api/sessions/${id}/input`, {
@@ -169,7 +169,7 @@ describe('TerminalTile in a real browser', () => {
await page.evaluate(async (id) => {
await fetch(`/api/sessions/${id}`, { method: 'DELETE' });
}, sessionId);
}, 20000);
});
it('gates app-level chords out of Pane B instead of forwarding their raw bytes', async () => {
// Regression guard for PR #453's Ctrl+K/Alt+1/Alt+B leak: Pane B had no