Repository navigation
MW M2+M3: sminos declared channels at the endpoint and the hub's channel retention - #766
Conversation
…M2 and M3 built side by side (Decision Log 12) Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…fore the endpoint changes (MW M2) test/endpoint/mixed-fleet.local.test.ts runs Interfaces §K's script (one endpoint, a scripted sminos without `channels`, the hub in Miniflare) and compares every frame down and up with mixed-fleet-baseline.json, which its capture mode wrote twice on 77af813 with `cmp` agreeing. Both variants (member frames without and with `channels`) equal the baseline and each other, and the comparison refuses an added field each way, an altered or added `known` entry and a dropped frame. The suite joins TIMING_NODE_TESTS. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…nown`, and a channel refused as a member's project (MW M2) The welcome lists `channels`, last, only to a hello that lists it. From then each held lane A member's counted `channels` (memberChannels: entries that pass isChannelId, each once, the first 128) are logs this machine holds a member of, read in one place, sminosView().sessionProjects(), so a channel whose log sminos opened without follow is `known` while such a member is held. readMember neither requires nor checks the field. A member frame whose project is a declared channel's id is logged and handled as `gone`, with or without the capability (Interfaces §C, §D). Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…d` (MW M2) Statements.target opens with isChannelId, before the registry or the folder's own .smns is read, so `session.projects.link`, `addFolder`'s `into` and the follow-the-file link all refuse it with `channel-id: <id> is a sminos channel, not a project: a folder is linked to a project`. The code joins PROJECT_REFUSALS (Interfaces §D). Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…ed and brings it back A hub row whose id passes isChannelId carries `unlisted`, the time since which no counted projects record has listed it as known. A pass at each record accepted (the same bytes again included) and at each sweep reads the records that verify under the head, and applies the listing only while those are still the records held: a channel's row listed is active with no clock, unlisted starts its clock, seven days unlisted retires it, and a retired row listed again returns to the grid. The registration reads the records already held, so a listing stored before the hello keeps the clock stopped. The alarm adds each clock's end and a daily recheck while a row is listed; a passed deadline the sweep's pass could not act on waits the retry. Rows that are not a channel's are never touched. Interfaces §F of docs/doperpowers/plans/2026-11-18-mw-sminos-channels.md, with the suite's seams and apps/desk-hub/test/channel-retention.test.ts. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…ared channel's case (MW M2) Interfaces §I's three edits: the three sminos hellos and the two welcomes list `channels`; `bindings` gains `channel:C`; a fourteenth case opens the channel's log without follow, states it on S1's lane A member frame (case 11's frame with `channels` added) and then not, and the new scene `holds` waits for the endpoint to count, then stop counting, a member of that log. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
… in the other's directory (MW M2)
projects.local.test.ts: with sminos on A listing `channels`, a lane A member stating C and C's
log opened without follow put {id, name} of C in A's record's `known`, B holds that record and
hands its sminos C as a hub project, and both go when the member does.
Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…idge; memberChannels bounds its reads (MW M2 review) P1: a first lane B member frame whose project is a declared channel's id returned before the handed-off mark, and `gone` had nothing held to tell, so authorization kept the spawner as owner. The refusal now marks the engine session handed off and tells the record's listeners a lane B target, holding and listing nothing; targets.test.ts pins the subscription ended, `grade` for the spawner's status and send, and the app session's mark on disk. P2: memberChannels takes one pass in the frame's order and stops at the 128th distinct id. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
… only from the alarm and stores From the reviewer-high review of 2ab32ad..28cff5e: - storeProjects runs its pass again while each finds the records it verified replaced, so it answers only once a pass has applied the records held after the record was stored: a listing reaches the rows before the machine can send the record that withdraws it. A head that cannot be read still leaves it to the alarm. - The channels' pass runs from the alarm and from accepted stores, never from redeem's housekeeping sweep, the route Access does not guard. - A stored record arms the alarm for its owed pushes before the pass can suspend. - An overdue channel deadline adds no earlier than now plus the retry wait, with no memory of a failed pass, so a fresh instance never sets the alarm for at once. - Tests: a test-only barrier holds a pass between its verification and its apply; it pins section F's Order (no grid frame omits a row a record stored during the held sweep lists) and the store's answer; plus a redemption, a fresh instance's alarm, and the mixed fleet's exact shapes and frames. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…uiet window samples before it is judged (MW M2 review) P2: the presence waits for its checkout held, each member frame for its session held and its audience told, `restated` for the restatement closed; the quiet window samples the counts after each wait and before judging the window. The comparison with the committed baseline is unchanged and green (no re-capture). Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
… is away (MW M2 review) P3: the scene compares the view's optional answer with `held` directly, so `held: false` no longer passes while no sminos is connected. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…ass per store From the reviewer-high review of b1fc214: - In the step that accepts a projects record (stored, or the same bytes held already), the channels' rows it lists as known take section F's listed side: the clock cleared, a retired row made active again, its seedProject and summary following before the answer. This side only keeps or brings back a row, so a reset before the pass, or a pass that applies nothing, can no longer lose a listing to the withdrawal queued behind it. - The store runs one pass again; a pass that finds the records replaced leaves them to the newer store's own pass, and the re-run loop that could starve a relay under sustained writes is gone. - The listed side is one function (applyListed), shared by a pass's apply and a record's acceptance. - Tests: a reset while the listing's pass is held, then the withdrawal, runs the seven days from the withdrawal; a listing with the head unreadable clears the clock; a retired row listed comes back with its summary while its store's pass is held. The round-1 case is kept, now asserting the clock is cleared at acceptance. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…ands one off (MW M2 review round 2) P1: the refusal resolves the record's app session as the join does (the engine host's live rows, else the spawn's proof through #bySpawn, now given the proof since the member is held nowhere) and places it, so the app session's mark is durable and a `/clear` on either side finds it handed off; with no app session found the engine session's mark stands. P2: the mark and the tell to authorization come before anything is awaited. P3: a member already joined keeps its app session's mark (placed again) and no engine mark is written back. The join's `engine.sessions` read is #liveRows, shared by both. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…refusal's hand-off (Decision Log 13, 14); two M3 deferrals in the tech-debt tracker Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…e its app session is looked up (MW M2 review round 3) P1: #refusedSight kept the earlier held record (lane A, or lane B unjoined) granting while it awaited engine.sessions, and after a `/clear` #bySpawn joined that still-held member, so no notice reached a spawner subscription on the replacement engine session. Now the mark and the tell come first, then `gone`'s synchronous part (the record dropped, its readers told) before anything is awaited, and the lookup runs with #bySpawn joining nothing (`join` false), which tells the app session it passes the sight to. targets.test.ts pins the reviewer's case. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…wo round-3 P2s in the tech-debt tracker Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…hannels-2 Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…ew the xhigh panel Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…quest's opening Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7c29a8473a
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const verified = await this.countedProjects(); | ||
| if (verified === null) return 'unreadable'; | ||
| // From here on synchronous: the records found counting are the ones held as the listing is applied. | ||
| if (!sameHeld(verified.held, this.records.projectsHeld())) return 'moved'; |
There was a problem hiding this comment.
Fence retention passes against head and certificate changes
If an expired delegation is renewed while a retention pass is verifying records, the held machine/revision pairs remain unchanged, so this check allows results computed under the old head to be applied. For a channel already at its seven-day deadline, that can retire its row even though its held listing now verifies under the renewed delegation. submitState does not enqueue another channel pass, and scheduleAlarm skips retired rows, so the channel can remain incorrectly absent from the grid until another projects record or unrelated alarm arrives. Check the head version and certificate generation alongside the held revisions before applying the pass, and arrange a retry when either changes.
Useful? React with 👍 / 👎.
…frame of the same session (MW M2 panel) The panel's scalpel-2#2: a lane A-to-B frame paused in its lane change's `gone` while a replacement socket took a later frame of the session (a refusal), then resumed, held its stale member and joined it, so authorization read a record again. Each `member` frame, `gone` frames included, now takes a turn of its session; after each wait (the lane change's `gone`, the join, the lane B record's read in #report) a handler whose frame is no longer the latest returns, holding, joining and reporting nothing. #refusedSight sets nothing after its waits. `restated` and the ordinary path are unchanged. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…15); its logged findings and the accepted residual in the tech-debt tracker Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…anel, the link rule) The link takes nothing of a new sminos connection, neither its welcome (the restatement it opens) nor its frames, until the replaced connection's handler in flight has settled: every connection's hello and frames run through one link-level chain. A hello whose connection closed or was replaced while it waited is not taken. The per-session turn of 70113fb is reverted: members.ts and members.test.ts are back to 7c29a84's. The scenario moves to test/endpoint/rl10/replacement.test.ts: a real Rl10 and two scripted sockets, a paused lane change refused on the replacement, an empty restatement on it, and a replacement that closed while it waited. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…replaces the per-session turn (Decision Log 16); recordChanged outside the chain in the tech-debt tracker Sminos-Session: master-landing-architect#37052769 (MAWS on macbook)
…welcome (MW M2 link rule, review P1) The link now keeps the connection it welcomed, and that connection is the link's only while it is still the server's current one. `send`, `connected`, `adopted`, `restate`, the audience frames and `#frame`'s entry check all read that. A replacement is current from its hello, but the link welcomes it only at its turn. A frame that the replaced connection's handler sends while the replacement waits is dropped, so the replacement's first frame is its welcome, which sminos's handshake requires. The replacement test pins it with an `audience` frame from the paused handler. Its cases also release the gate only once the endpoint has taken the replacement, with nothing announced to the link's listeners before then (review P3). Sminos-Session: master-landing-architect#37052769 (MAWS on macbook)
…ision Log 16) Sminos-Session: master-landing-architect#37052769 (MAWS on macbook)
…dged though dropped (MW link rule re-check, P3) Sminos-Session: master-landing-architect#37052769 (MAWS on macbook)
|
Landed master-first as 1f34794. Class 1a (static, unit, probes) run 44650467618 is green on the merged tree (490074985, equal to the merge commit's); Step 0's hub half: the owner ran the plan's command against production on 2026-11-20 (UTC) and it printed Sminos-Session: master-landing-architect#37052769 (MAWS on macbook) |
and #786 landed; what is left of M4 Docs only. Sminos-Session: master-landing-architect#37052769 (MAWS on macbook)
…icts, the tracker merged with both sides' rows in the file's order Sminos-Session: ux-wave#10d85d03 (MAWS on macbook)
…ommit); no conflicts Sminos-Session: ux-wave#10d85d03 (MAWS on macbook)
The second of MW's two pull requests (sminos channels and threads, MAWS's half). It carries milestones M2 and M3 of
docs/doperpowers/plans/2026-11-18-mw-sminos-channels.md, built on master8a7f308ff, which holds the first (#765).Landing is gated on Step 0's hub half. The owner reads production's hub table for ids of version 8 (the document's "Step 0's commands"). M2 and M3 adopt the id rule, so this does not land until that read returns zero.
apps/org-protocol/vectors/channel-rule.jsonis unchanged here; sminos's T1 pins it from8a7f308ff.M2, the endpoint (Interfaces §C, §D, §I, §K):
channelsis listed in the welcome only to a hello that lists it.channelsintoknown. A lane A member'schannelscount toward the machine'sknownwhile that hello listed it. At most 128 count, they are read in one place (memberChannels), and a lane B member's count for nothing.channel-id. This coverslinkandaddFolderinto, whether the id comes from a record or from a folder's.smns.memberframe whose project is a channel's id leaves the session not held. A lane B frame refused this way still hands the session off from its spawner.channels.test/endpoint/mixed-fleet.local.test.tschecks that, for an sminos that does not listchannels, every frame up and down and the signed record are the frames master77af813a4sent for the same script. The transcript was captured from that commit before any endpoint line changed.M3, the hub (Interfaces §F):
known, and the next record that lists it makes it active again.GET /api/projectsand the grid frames carry no new field.Validation Evidence
e2e:desk-webon the head7c29a8473:scripts/ci-gate.sh <sha> --gates static,unit,probes,e2e:desk-web --label mw-channels-2→ci-gate: run 44423055050 success, with every job green: static, static-local, unit 1/4 to 4/4, probes and e2e:desk-web.d53b21991: run 44419172460. This is the first Linux run of the Mac-captured baseline, and it compares equal.d065b9042: run 44420964248.28cff5ee2: run 44418427506.b1fc2146f: run 44420766014.4a36045e4: run 44421820397.channelsinknownwhile a member states it:test/endpoint/rl10/sminos-channels.test.ts: 10/10.test/endpoint/projects-records.test.ts: 32/32.test/endpoint/projects.local.test.ts: 9/9. Across the hub in Miniflare, the record'sknownlists the channel and the second endpoint's directory hands its sminos the channel; both go when the member does.test/endpoint/mixed-fleet.local.test.ts: 5/5. This covers the oracle, the field isolation, and the comparison failing on an added field, an alteredknownand a dropped frame.77af813a4.cmpprinted nothing, andgit diff --exit-code -- test/endpoint/mixed-fleet-baseline.jsonprinted nothing.organdprojectsframes.src/services/index/statements.test.ts, 53/53.test/endpoint/rl10/members.test.ts: 19/19.test/endpoint/targets.test.ts: 40/40. These cases cover the lane B refusal's hand-off, including/clearbefore and after the refused frame.apps/desk-hub/test/channel-retention.test.ts, 19/19. Its cases:test/endpoint/rl10/conversation.local.test.ts, 2/2, on the edited fixture.git diff origin/master...HEAD -- test/endpoint/rl10/conversation.jsonshows §I's three edits and no others.git diff origin/master...HEAD -- src/shared/ipc/wire.ts src/shared/ipc/wire-manifest.json src/endpoint/hub-link.tsgit diff origin/master...HEAD -- apps/org-protocol/vectors/channel-rule.jsongit grep -n "8\[0-9a-f\]{3}" -- src apps ':!apps/org-protocol/src/channel-id.ts'doperpowers:reviewer-high, and every round was served by the requested model, a different model from the executors'.8a7f308ff..7c29a8473and returned "incorrect": two P1s and nine P2s, each confirmed by its verifier. The architect's dispositions are in Decision Log 15.scalpel-2#2is fixed at its root in40425b56f(Decision Log 16).Rl10now takes one frame at a time across a replacement connection too: a new connection's welcome and its frames wait until the replaced connection's in-flight handler has settled. Within one connection, frames were already handled one at a time.test/endpoint/rl10/replacement.test.ts(4/4) runs a realRl10with two sockets.7c29a8473: the panel's interleaving, and a replacement's empty restatement.welcome. It is red on the chain's first commit, where the replaced connection's paused handler could send anaudienceframe ahead of the welcome.f57e26d0afixed that: the link keeps the connection it welcomed, and nothing goes out on a connection that has not been welcomed.doperpowers:reviewer-highreviewed the whole panel-fix delta7c29a8473..87dc7c8dband found the P1 above, whichf57e26d0afixes. A re-check of the fix returned "correct", with one P3, listed below. Every review round was served by the requested model.e2e:desk-webon the headfb81bfafa:ci-gate: run 44432415041 success, with every job green: static, static-local, unit 1/4 to 4/4, probes and e2e:desk-web..Unresolved Review Findings
All of these are deferred in
docs/tech-debt-tracker.md, with the document's Decision Log 14, 15 and 16.Accepted as a residual:
src/endpoint/rl10/members.ts,#refusedSight(panelscalpel-2#1). A/clearcan replace an unjoined engine session before the refusal's lookup. The new engine session and the app session then stay unmarked until the new session's own frame arrives, which marks it synchronously.join, that record being the session's first, and a/clearin the lookup's window.src/endpoint/projects.ts, the signer's size bound (panelsweep#1). A record just under 256 KiB becomes unsignable once a channel is added. Master behaves the same for any addedknownproject, and the fleet is three orders of magnitude below the bound.apps/desk-hub/src/objects/registry.ts(panelscalpel-1#1,#2,#3). Three hub-retention edge cases:src/endpoint/registry.tsandmembers.tsrestated(panelscalpel-3#2,#3). A record signed during a reconnect's restatement can briefly miss a channel, or briefly list one. This is the existing project rule applied to channels, and it corrects itself at the next revision.test/endpoint/mixed-fleet.local.test.ts(panelscalpel-4#1,#2,#3). The oracle does not check:The oracle proves frames and
knownunchanged without the capability; these three belong to other suites.apps/desk-hub/src/objects/org-records.ts(theacceptedcallback on identical bytes) andregistry.ts(sameHeld). A resend of identical bytes after an eligibility change does not fence an older sweep. That sweep can restart a listed row's clock, and the resend's own pass repairs it unless the Registry resets first.registry.ts, the store's single pass. Sustained writes from two machines whose records overlap each other's verification can keep every pass reporting moved. A finite burst drains, and projects records change far below that rate.registry.ts(channelRows). The pass reads everyhubrow to find the channel rows, even when none exists.org-records.ts(verifyProjectsRecord→machineKeys). A pass re-evaluates the certificate set once per record.src/endpoint/rl10/members.tsrecordChanged, pre-existing on master (Decision Log 16). It runs outside the link's one-frame chain. Its listing report can therefore queue behind a frame's withdrawal and list a lane B session that has just gone, until a later frame corrects it.src/endpoint/rl10/link.ts#liveandsrc/endpoint/calls.ts's upstream check (the link rule's re-check, P3). A replacement's hello can wait for its turn. During that wait, a read call (sminos.read,rows,difforoutput) on a lane A subscription still bound to the old upstream answersrequested: true, even though the link drops the frame. The read is not replayed, and the subscription ends as unavailable.Residue
None of its own. The staging deploy of the merged master, its
X-Desk-Buildread, and the hand-off of Interfaces §J to the session holding the parent are M4's steps for the architect, after landing.Sminos-Session: master-landing-architect#37052769 (MAWS on macbook)