Skip to content

endpoint notify: a lane A question raised after its project opened reaches the hub (P5 O10, RL10) - #345

Merged
SSFSKIM merged 4 commits into
masterfrom
p5-o10-notify-raised
Oct 29, 2026
Merged

SSFSKIM merged 4 commits into
masterfrom
p5-o10-notify-raised

Conversation

@SSFSKIM

@SSFSKIM SSFSKIM commented Oct 29, 2026

Copy link
Copy Markdown
Owner

Summary

A lane A question raised on a cut-over machine never became a card. The hub's presence pending stayed 0, the endpoint never sent notify, and it never wrote notified.json. This was seen in production on the Mac mini after B2's cutover, for every session in every project.

sminos (the RL10 client) sends a project's complete {t:"pending"} set only at an open, a drop, a reconcile loss or an outbox overflow. Every later raise and settlement goes up as a single sub-less session message of kind raised or settled (sminos_requests.py:480/:520 → queue). That is RL10's contract: complete state at each welcome, single messages in between. The endpoint's Notifier was fed only from the complete sets (rl10/link.ts #pending). #session handed raised and settled to the channel plane alone, so the hub's pending count never rose above 0.

The fix is in src/endpoint/notify.ts and src/endpoint/rl10/link.ts:

  • The Notifier keeps, per project, each session's lane A request ids.
  • A complete set replaces the project's ids, and settles any session it leaves out, as before.
  • requestMessage adds an id on raised and removes one on settled, then sends pending(session, size). It takes the session from the envelope, because a settled body carries no session.
  • A repeated raise, a settlement for an unknown id, or a body with no id changes nothing.
  • forget drops a session's ids. withdrawn keeps them, so a session listed again is told its count.
  • A session restored from notified.json holds an empty set, and the next complete set settles it.
  • Lane B's counts are untouched.

The fixture test/endpoint/rl10/conversation.json gains a notify scene, which checks the last notify for a session and notified.json. It also gains case 12 (raise, raise, settle, settle). Cases 8 and 11 now end with notify assertions.

Validation Evidence

  • Tests failed first, then passed.

    • Seven new Notifier unit tests in test/endpoint/records.test.ts failed with notifier.requestMessage is not a function.
    • The fixture failed at the defect: "case 8 … step 4 (notify): no a notify waiting 1 … within 10000 ms".
    • Case 12, run against the pre-fix src/endpoint, failed with "step 1 (notify): no a notify waiting 1".
    • GREEN on the fix: test/endpoint + src/endpoint gave 473 passed, 1 skipped; tsc -p tsconfig.node.json exited 0; eslint was clean.
  • Focused tests on the merge head a9796a4 (after merging origin/master bd6b4b0): vitest run test/endpoint/records.test.ts test/endpoint/lane-b-notify.test.ts test/endpoint/rl10/ test/endpoint/cli.test.ts gave 9 files, 100 tests passed.

  • Staging proof. This used desk-hub-staging and the devcloud VM's scratch scene only; nothing in production was touched. The probe lives on evidence branch p5-o10-notify-staging (9b1f2e0), which is not for merging.

    • With the fix: a stub lane A session raised a blocking mcp__sminos__AskUserQuestion.
      • The endpoint's notified.json read {"0fb74622-…":{"project":"b7d29bc1-…","pending":1}}.
      • The hub's presence read {"t":"presence","online":true,"pending":{"0fb74622-…":{"project":"b7d29bc1-…","kind":"waiting","pending":1}}}.
      • After the decline, notified.json read {} and a fresh socket's presence read "pending":{}. The verdict was PASS 10.
    • Control run, same harness without the fix: the question showed pending in the pane, but notified.json was still {} after 90 s. That is the production defect.
  • Gate: scripts/ci-gate.sh <worktree> --gates static,unit,probes,e2e:desk-web-hub --runner macos --class1a pool --lane hosted at the merge head a9796a4 (tree b9f86fb3e; ci-gate ran that exact sha as ci/notify-raised-m-a9796a47, so the gated tree is the head's): run 40852192868 success, with static, unit 1/4 to 4/4, probes and e2e:desk-web-hub all success. No flaky: line (flaky count 0). An earlier run on the pre-merge head b7496e3 (40850997678) was also green, but it ran before P5 O3-B: the e2e groups on the daemon shape #336's daemon-shape harness landed.

  • Review: reviewer-high on c6c5235..b7496e3 found no material defect in the Notifier changes. Its in-memory checks covered:

    • raises before the session is listed;
    • duplicates;
    • a complete set replacing single messages;
    • settlements, and restoring from notified.json after a restart;
    • lane B isolation;
    • withdraw and relist, and forget;
    • a reconnect's reconciliation.

    Its one finding is below.

Unresolved Review Findings

  • [P2] Case 12 adds four up lines (conversation.json:337–339). The sminos replay of the byte-for-byte copy (sminos/tests/rl10_conformance.py STAGE, around :588) has no entries for (12,0), (12,2), (12,4) or (12,6). If the copy is refreshed without them, the replay times out waiting for req-3 and req-4. The fix belongs in the doperpowers repository, and the coordinator owns it once this lands: refresh sminos/tests/rl10-conversation.json to blob 4d91747bb65a5e8ee1b00c0c19150900a6650bee and add the four STAGE entries. Until the copy is refreshed, sminos's replay stays on the old fixture and keeps passing.

Residue

  • sminos fixture refresh: handled by the coordinator, as described above.

Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)

…aches the hub (P5 O10, RL10)

sminos sends a project's complete pending set only when it opens the project; every later question goes up alone as a
session-wide `raised`, and each answer as a `settled` naming its request. The Notifier was fed only the complete sets,
so on a cut-over machine a question asked after the welcome never moved its session's count: no `notify waiting`, no
`notified.json`, no card.

The Notifier now keeps each project's lane A requests by id per session: a `pending` frame replaces the project's
(settling a session it leaves out, as before), a sub-less `raised` adds its request and a `settled` takes it, each
change told as `waiting` or `settled` with the count. A raise already held, or a settlement of a request not held,
moves nothing; a forgotten session's requests go with it; a restored session holds none until sminos restates the set.
RL10's `#session` hands every `raised` and `settled` to it beside the `host` case. Lane B's counts are unchanged.

conversation.json: case 8 asserts the raise's `waiting 1`; case 11 the restarted endpoint's `settled 0` from the
complete set after the welcome; a new case 12 a raise, a second, and both settled (waiting 1, 2, settled 1, 0), each
checked against notified.json.

Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)
Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)
Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)
Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-29T09:54:47.933907Z a9796a4 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@SSFSKIM
SSFSKIM merged commit a05b853 into master Oct 29, 2026
SSFSKIM added a commit that referenced this pull request Oct 29, 2026
…project opened reaches the hub's presence (B2 step 7's card)

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
SSFSKIM added a commit that referenced this pull request Oct 29, 2026
…nch counts one request 1, 0, 1; case 11's down-time settle takes the old connection)

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
SSFSKIM added a commit that referenced this pull request Oct 29, 2026
…he spine series

The three daemon-idle files: the imports join both sides; the spine case keeps M5's spineLine, SPINE_RELEASED_RUN and the 'spine alone' case on master's Rule B. SPINE_RELEASED_RUN gains pairLoad (IdleRun now names it), the spine line prints each window's 30 s pair as master's lines do, and its test fixtures carry loadPair. services.js and its three chunks are byte-identical to 4c3fcbe's.

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
SSFSKIM added a commit that referenced this pull request Oct 29, 2026
Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)
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