Repository navigation
Description
Colour each card as its record arrives (drift-start, records, drift-settle); a resource that never reports becomes not-observed / not-reached. Accepted when cards change colour one by one in the choudoufu-estate demo, and the e2e suite asserts it.
Part of #993.
Acceptance: read verdict lines and recorded artifacts, never exit codes alone. Anything that needs an emulator corpus, an estate run or a real cloud is run by the maintainer by hand. Red-first only for new guards.
Where it stands
Built and on main: the B5 unit merged at c508909 on integration/choudoufu-engine, and path 1 landed on main as behold e765bf6 (chant 1cf732818, choudoufu e5023addda). Unit tests passed at epic-ready. What remains is the maintainer's live run.
- The read:
driftStreamArgv,streamDriftandrootStreamTransportin src/workspace-reader.ts runchant workspace drift --member <name> [--read <r>] [--resource <addr>] --stream(orBEHOLD_DRIFT_CHANT). chant main has--stream(packages/core/src/cli/main.ts:990); no chant release has it yet. - src/drift-stream.ts
runDriftStreamturns each line into adriftSSE frame (begin, start, record, settle, failed, end) on/api/events, and folds unanswered addresses into not-observed / not-reached at settle. Colour comes fromtoneFor, which since B2 (multi-engine B2: colour from the drift record #995, closed) lives in src/drift-tone.ts:134. - Route:
POST /api/workspace/drift/stream {member, addresses?}(src/server.ts:1852), refused under--public, one run at a time (409drift-streaming),{stop: true}stops it. - Page: web/drift-stream.js and
markStreamedDrift(web/app.js:4385); palette row "Stream drift card by card: ". AGENTS.md section "Drift, streamed card by card (multi-engine B5: streamed drift #998)". - On a choudoufu member behold asks once per resource block (H2, choudoufu#2245, has no whole-estate stream), so cards change colour resource by resource.
Carried to #1005 (waits on the chant release, INTENTIUS/chant#4473): registering DRIFT_STREAM_CHANT_FLOOR with its CHANT_FLOORS entry, and replacing the copy in src/drift-line.ts with chant's @intentius/chant/drift-record.
Acceptance
-
src/drift-stream.test.tspasses: argv, the H2 fixture (src/fixtures/drift-stream/choudoufu-resource.ndjson) decoding, the refusals,resourceBlocks, the order of per-resource frames, not-reached at settle, a failed command and an undecodable line (unit tests passed at epic-ready, per the epic-ready comment). -
just e2e-streamed-drift(e2e/streamed-drift-e2e.sh, e2e/streamed-drift.mjs, fake chant in e2e/fixtures/fake-chant-drift) prints its all-green verdict: from the SSE frames, 21 starts and 21 records arriving apart in time andaws_cloudwatch_log_group.team_c_2settling as not-reached; from the headless browser, every monolith card reads as reading before its colour, cards change colour at least half a step apart, the silent card ends not-observed / not-reached, and drifted, unclaimed and in-sync cards end in their tones. Needs Docker, choudoufu and a scratch floci (maintainer run). - In the choudoufu-estate demo with
BEHOLD_DRIFT_CHANTset to a build of chant main, the palette's "Stream drift card by card" row colours the cards one resource at a time, with a recorded screenshot or capture of the frames attached here (maintainer run).
Open questions
None.
Activity
Streamed drift: colour each card as its record arrives (#998)
Merge unit/b5-streamed-drift: #998 streamed drift
lex00 commentedon Oct 25, 2026
B5 landed on
integration/choudoufu-engineat merge c508909 (unit commit e12712d, branchunit/b5-streamed-drift).npx tsc --noEmitis clean andnode --check web/app.jspasses. No test, e2e or demo was run.What landed
src/workspace-reader.ts, appended at the end so it stays clear of B2's non-streamed read in the same file.driftStreamArgv(:404) buildsworkspace drift --member <name> [--read <r>] [--resource <addr>] --stream.streamDrift(:430) decodes each stdout line as chant prints it, and kills the read on the first line that does not decode.rootStreamTransport(:456) runs the root's own chant, orBEHOLD_DRIFT_CHANTwhen that is set. It does not go through the buffered read budget, because the read is a stream and not one document.src/drift-line.tsholds the line types and the checks, following chant'sdecodeDriftLine,driftRecordandnotReachedRecordat chant fdce0d963. They are written out because the chant behold depends on (0.124.52) does not export@intentius/chant/drift-recordyet. Once a release does, this file can become a re-export. C1's H2 fixture is copied tosrc/__fixtures__/drift-stream/.src/drift-stream.ts:runDriftStream(:128) turns each line into adriftSSE frame (begin, start, record, settle, failed, end) on the existing/api/eventschannel. At settle, every expected address that no record answered becomes not-observed / not-reached, using chant's fold rule. It goes out as a record frame before the settle frame, so no card is left reading. A read that fails is afailedframe, and its cards keep the colour they had. A read that never printed a start stops the run.toneFor(record)(:55), keyed by status. An unknown status is neutral and says so. B2 (multi-engine B2: colour from the drift record #995) has not landed (there is no unit branch), so its(status, read)table is not used yet. Swapping it in means replacing that one function.POST /api/workspace/drift/stream {member, addresses?}(src/server.ts:1838), JSON only. Under--publicthe request guard refuses it. Only one run goes at a time (409drift-streaming), and{stop: true}stops it. It is listed inGET /api.web/drift-stream.jsfolds a frame into the IR on screen in place, the wayweb/pending.jsdoes.markStreamedDrift(web/app.js:4384) repaints only the cards a frame moved. It puts the bar and outline in the record's tone and setsdata-drift-status,data-drift-toneanddata-drift-not-reached. A card that is reading getsdata-drift-reading: dimmed and dashed, with its fill and_statusleft alone (styled in web/index.html). The palette has a "Stream drift card by card: " row for each declared member.Decision: per resource on a choudoufu member
H2 (choudoufu#2245) plans one resource per
live-plan -resourcecall, and writes that resource's records when its plan ends. There is no whole-estate stream. So on a choudoufu member behold asks once per resource block, one block after another. It takes the addresses the page sends and keeps only resource addresses: instance keys are dropped, data sources are left out (-resourcerefuses them), and each block is asked once. The cards change colour resource by resource. Any other member is asked once, without--resource. Frames are keyed by the workspace member behold asked about, because choudoufu writes its estate name inmember.Still missing
src/drift-stream.test.tscovers the argv, the H2 fixture decoding, the refusals,resourceBlocks, the order of the per-resource frames, not-reached at settle, a failed command and an undecodable line. Runnpx vitest run src/drift-stream.test.ts.just e2e-streamed-drift(e2e/streamed-drift-e2e.sh, plus e2e/streamed-drift.mjs). It sets up the choudoufu-estate demo the waybehold demo choudoufu-estatedoes (Docker, choudoufu, scratch floci). For the drift read only, it points behold at a fake chant (e2e/fixtures/fake-chant-drift/chant) that emits a timed stream per resource and stays silent foraws_cloudwatch_log_group.team_c_2. It asserts from the SSE frames: 21 starts and 21 records, records arriving apart in time, and the silent resource settling as not-reached. It asserts from a headless browser: every monolith card reads as reading before its colour, cards change colour at least half a step apart, the silent card ends not-observed / not-reached, and the drifted, unclaimed and in-sync cards end in their tones. The maintainer runs it by hand.chant workspace drift --streamis B2's chant-side work and is not in a release. To watch the demo against a real chant, setBEHOLD_DRIFT_CHANTto a chant built from that branch.DRIFT_STREAM_CHANT_FLOORand itsCHANT_FLOORSentry once the release is known.toneForwith its table, and dropsrc/drift-line.tsin favour of chant's module once a chant release ships it.Merge unit/b2-colour-from-record: #995 colour from the drift record
lex00 commentedon Oct 25, 2026
Path 1 of the multi-engine engine tier is on main: choudoufu e5023addda, chant 1cf732818, behold e765bf6 (each a merge commit of integration/choudoufu-engine, tree identical to the tested tip). Ready for the maintainer: cards changing colour one by one in the choudoufu-estate demo, and
just e2e-streamed-drift(needs Docker, choudoufu and a scratch floci). Unit tests passed at epic-ready.lex00 commentedon Oct 26, 2026
Run steps for the two maintainer items, against a local chant build. Nothing here was run. No code change was needed for either item: the route, the stream, the page and the e2e are on integration/engine-ship as they landed (behold 6bb48ec is the tip these steps were written against), and the real
chant workspace drift --streamis on chant's integration/engine-ship (packages/core/src/cli/main.ts:990). Neither acceptance item can be ticked from code; both are run results.0. Checkouts and a local chant build (shared with behold#1000)
Every repo at its
integration/engine-ship. Paths are examples.The stamp is the same number as the npm release, so the
--streamline is the check that the tarballs went in. The floors behold guessed at 0.124.53 (DRIFT_RECORD_CHANT_FLOOR,ADOPTION_REPORT_CHANT_FLOOR) read as unmet on this build. The streamed read has no floor, so neither run below needs them.1.
just e2e-streamed-driftIt sets the demo up in a temp dir, serves it on :4698 (
BEHOLD_E2E_PORT), and pointsBEHOLD_DRIFT_CHANTat the fake in e2e/fixtures/fake-chant-drift; every other read is the local chant from step 0. Pass is the last line,streamed drift e2e: all green, after the ticks for the route (400, 202, 409), the frames (21 starts, 21 records arriving apart,aws_cloudwatch_log_group.team_c_2not-reached) and the page. The behold log is${TMPDIR:-/tmp}/behold-drift-e2e.log. The container goes on exit.2. The choudoufu-estate demo with the real chant
When it is serving:
Open http://localhost:4321/, then ⌘K and "Stream drift card by card: monolith" (the same as
curl -X POST localhost:4321/api/workspace/drift/stream -H 'content-type: application/json' -d '{"member":"monolith"}'). Each card should dim to reading, then take its colour one resource at a time, because chant asks choudoufu once per resource block. Record the screen while it runs, and attach that and /tmp/drift-frames.txt here. The frames for one run go begin, then per resource a start and a record, then settle and end. Afailedframe carries chant's own words.Stop with Ctrl-C, then
bash /tmp/choudoufu-estate-demo/scripts/choudoufu-down.shto remove the floci container.Things that may need a fix in that run, none seen yet: the real stream's per-resource timing (with choudoufu's real plan each record may take seconds, so the run is slower than the e2e's 0.6 s steps), and a resource chant reaches that the page did not list.
lex00 commentedon Oct 26, 2026
Ready for the maintainer, with one finding. Epic-ready (2026-10-26): behold main 5676314 is the merge of integration/engine-ship, tree identical to the tested tip aa885d8. On that tip, with chant's integration build (9ae806b69, npm pack stamped 0.124.53, installed --no-save): tsc, build, and vitest with 4723 passed, 0 failed; e2e adopt-terraform, adopt-pulumi, pulumi-workspace, multi-engine-demo and three-cloud-change-set all green.
e2e/streamed-drift-e2e.shdoes not pass at behold main 5676314: step 1 fails with "an unknown member answered 404".behold demo choudoufu-estateservesestate/monolithand not the workspace root, so the route finds no declared workspace (code no-workspace, 404) before it can check the member (400). The same failure happens at behold c833451, before this epic, with the same chant build and choudoufu, so this epic didn't cause it; it needs its own fix before the streamed-drift item can tick. The other item (the choudoufu-estate demo with BEHOLD_DRIFT_CHANT set to a chant build, recorded frames) is the maintainer's, as before.lex00 commentedon Oct 26, 2026
Audit correction (2026-10-26):
Both remaining items are blocked, not only the e2e.
behold demo choudoufu-estateserves the estate dirs (demos.test.ts:173), not a workspace. The palette row "Stream drift card by card" exists only whenprojectInfo.workspaceis set (web/app.js:12446-12449), and the route answers 404no-workspacebefore the member check (src/drift-stream.ts:211).The posted run steps are stale:
DRIFT_STREAM_CHANT_FLOORexists.Round 2's #1014 unit makes the demo serve the workspace. Fresh steps follow when it lands.
lex00 commentedon Oct 26, 2026
Ready for the maintainer (epic:engine-ship round 2, 2026-10-26). behold main is a08dadc, whose tree equals the tested tip 9f8d257. Main CI on a08dadc (run 40407758155): success.
The audit correction's blocker is fixed:
behold demo choudoufu-estateserve the declared workspace, so the palette row "Stream drift card by card: monolith" appears and the route reaches its member check.DRIFT_STREAM_CHANT_FLOORisCHANT_RELEASE.version(0.124.53). Published chant 0.124.52 is below it, so the stream needs the local build. The floor is not checked whenBEHOLD_DRIFT_CHANTnames the chant to run.Orchestrator evidence, which is not a tick because item 2 is marked as a maintainer run: on 9f8d257, with local chant 0.124.53 (packed from chant 4b359afcc), choudoufu 567c49d89a and scratch floci,
bash e2e/streamed-drift-e2e.shprinted "streamed drift e2e: all green":Nothing here runs plunge, so the plunge#27 endpoint setting does not apply.
0. Worktrees of each main, and the local builds
If a long TMPDIR breaks the provider handshake (the epic's runs hit this), run with
TMPDIR=/tmp.1. Item 2:
just e2e-streamed-driftPass is the line
streamed drift e2e: all greenafter the step 0 to 3 ticks. Askip:line exits 0 and is not a pass (no Docker, or no choudoufu at CHOUDOUFU_BIN). The behold log is${TMPDIR:-/tmp}/behold-drift-e2e.log.2. Item 3: the demo with the real chant stream
When it is serving, keep the frames in a second terminal:
Open http://localhost:4321/?alike=0. Stacking has to be off, because a streamed record does not paint a stack card yet (cardsFor matches individual cards only). Then press Cmd-K and pick "Stream drift card by card: monolith", or run
curl -X POST localhost:4321/api/workspace/drift/stream -H 'content-type: application/json' -d '{"member":"monolith"}'. Each card should dim to reading, then take its colour one resource at a time. The real choudoufu plan per resource is slower than the e2e's 0.6 s steps. Record the screen and attach the recording and /tmp/drift-frames.txt here. Stop with Ctrl-C, then runbash /tmp/choudoufu-estate-demo/scripts/choudoufu-down.shto remove the floci container.lex00 commentedon Oct 27, 2026
Ready for the maintainer (consolidation-graph, 2026-10-27)
behold main is 8b74db5, whose tree equals the epic-ready tested tip fd1dd6a. chant main is 47b8594e3. This refreshes the round-2 comment: those steps named behold a08dadc and are replaced by the run sheet entry below.
What epic-ready proved: with scratch emulators, behold's safe env and the local chant build (b6281ef154 as 0.124.53),
e2e/streamed-drift-e2e.shprinted "streamed drift e2e: all green" with no real-cloud call. That run was at 8236662, an earlier integration tip, and it is the orchestrator's, so item 2 stays unticked as a maintainer run. src/drift-stream.test.ts passed in both vitest runs at fd1dd6a (published chant 4906 passed, local chant 4914 passed).Left:
just e2e-streamed-drifton your machine, verdict "streamed drift e2e: all green" and a clean safe-env scan.BEHOLD_DRIFT_CHANTat the local chant build, cards colouring one resource at a time, with the recording and the frames attached here.Commands: run sheet entry B8 in engine-wt/goals/consolidation-graph-1-runs.md.