Skip to content

test(fix): Compare cold startup events on one clock - #198

Merged
tony merged 3 commits into
notebook-pane-waitfrom
cold-return-trace
Dec 6, 2026
Merged

tony merged 3 commits into
notebook-pane-waitfrom
cold-return-trace

Conversation

@tony

@tony tony commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

Refs #5.

What changed, and why

A delayed trace message could hide a caller that returned on time. The fixture reads the caller’s result under the original deadline and compares the root exit with the caller return on the same native BEAM clock. Both cold-start entry points keep their original retirement and observation budgets.

Checks run

Both cold-start cases ran with the loader suspended. A delayed-message control during the investigation distinguished event time from mailbox delivery. The broader startup qualification remains in issue #5.

  • Cold-start integration passed in 4.05 s.

Review evidence

The cold-start fixture owns event observation. It tests supervisor and connection startup, measuring root exit and caller return on the same monotonic clock.

The fixture changed without a runtime change. In a separate controlled run, a relay delayed delivery of the exit trace until the loader resumed. The old fixture returned :root_exit_not_observed for both entry points in 1.658 s with both roots gone. The corrected fixture passed both in 3.408 s. Moving the recorded return before the actual exit still failed in 0.661 s.

Merge stack

This PR follows #197 in the tested merge order. The comparison shows this PR’s own changes. Stack #206 · Changes in this PR

All six required Linux jobs passed on dfaa2f302. GitHub records the stack merge at 15b285de9. CI run · Merged commit

Tool use

Codex extracted this change from #169 and ran the checks above on the topic branch. A separate Codex reviewer checked the component boundaries and the two corrected test fixtures.

tony added 3 commits December 5, 2026 19:05
why: The cold-start fixture waited for an asynchronous trace before
checking the caller's timely return. A late trace could hide evidence
already in its mailbox even when the exact Root had exited.

what:
- Observe the caller's return while the code loader is suspended.
- Verify the killed Root's event time precedes the caller's return.
- Keep the original startup, return and cleanup budgets.
BEAM trace events with :monotonic_timestamp use the VM’s native unit. Record the API return in that same unit so exit ordering holds on every supported Linux time source.
@tony
tony changed the base branch from main to notebook-pane-wait December 6, 2026 01:07
@tony
tony force-pushed the cold-return-trace branch from f7bf615 to dfaa2f3 Compare December 6, 2026 01:08
@tony
tony added this pull request to stack #206 December 6, 2026 01:08
@tony
tony merged commit 15b285d into main Dec 6, 2026
6 of 10 checks passed
tony added a commit that referenced this pull request Dec 6, 2026
why: A tmux hook could add output to a pane or option read. A large
MCP reply could hide an operation outcome or advance a cursor before
the client received the page.

what:
- Fit the Program listener to the server socket path, wake waiters on
  exit, and retry pane removal after a lost reply (#191, #192, #193).
- Keep MCP operation outcomes readable and size pages before advancing
  their cursors. Show the STDIO client reading a result (#194, #195).
- Keep hook output out of pane captures and option reads. Use
  `Pane.wait_for_text/4` in the notebook (#196, #197).
- Check root exit separately from trace delivery in cold-start tests
  (#198).
- Document checkout dependencies, inherited sockets and capability
  APIs (#199, #200, #201).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant