M34: chant workspace blocks (members, records, gates as attention) #73
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Blocked by: nothing (S21, #70: go). Related: #74 (the shell environment: needed where node comes from
.bashrc), #75 (approve in shared sessions, part of this), #76 (chant drafts).Workspaces track. A chant workspace as a block: members as cards you open shells, agents and diffs on, records with their state, and gates waiting in any member as illogical attention you can approve. Read through chant's read contract only (
ws-017,ws-052); review actions stay hud's. Start from branchs21-workspace-block(throwaway, but the shape is right) andspikes/s21-chant-workspace(the reader and composer, with fixtures).BlockType::Workspace, config{root, env}.sh -con the block's host (one exec on a VM) runsworkspace ls --json,check --format json,records --current --jsonandstatus <env> --jsonin parallel, through the workspace's own chant:$CHANT, elsenode_modules/.binhere or in a parent, else PATH. If there's none, it says so.because, errors and warnings fromcheck, releases, gates), nested workspaces opening as blocks, records withblockedByand drift, and an attention headline.refreshand afterapprove.chant/lifecycle,status --porcelain,diff HEAD; about 0.1 CPU-s), with a full read only when it changes.chant/lifecyclelater.needs_inputwith "member: op waits at gate g". Approve runs chant'sapprovein the member's directory, owner and editors only (#75). Run op opens a pane runningchant run <op>.illogical workspace [DIR] [--env E];chant.workspace.json;open_workspace;describeandcall(refresh,approve,member,state).npm ciof a pinned chant);illogical workspace ~/dev/intentius/chant(afternpm install) shows its members. A gated op in a member shows as attention within about 5 s, the phone can approve it, and the nextchant runwalks through.Starting point: branch
s21-workspace-block(pushed; one throwaway commit on top of the S21 spike). Throwaway code, but the shape is right.S21 didn't try these; M34 should check them:
Runner::Machine; the VM needs node,npm ciand a fingerprint run through the provider.Possible extras, out of scope unless cheap:
chant workspace graph --intent <path> --jsonbehind a file or diff block ("why is this line like this": decisions and pinned artifacts for a file).chant/lifecycle, so gates reached in CI show without a manual fetch.Added from S22 (studio apps,
spikes/s22-apps): write gate attention against a gate, not against chant.A studio box's repo is a chant workspace too (members
app,delivery,box; its release stops at chant'sshipgate). The studio app block (#85, M35) will get its gates from hud in the box (hud's work board,GET /__hud/api/work, readsworkspace status), not by running chant. illogical can't run commands in a hosted studio box or a planter box on Fountain.So that both kinds of block land in the same place on the swarm:
{member, op, gate, env, since, expires, approvals, needed, command}, plussource(chant on this host, or hud in a box). Theneeds_inputreason, the bundle key and the card come from that type, not from the reader.chant approve … --approver <person>(#75), and in M35 whatever hud offers.Nothing else in M34 changes. In particular the workspace block stays for local workspaces and isn't widened to boxes. "A workspace on a VM tab" would work for a box on your own wispd (the box has node in
~/opt/nodeand its own chant), but M35 is the way in for boxes in general.Merged into local main (
c88c1e7, M34 branch m34-workspace8bb696c; CI green on linux 799 and macos 798). Not pushed. On geek: chant's 25 members in 1.6 s through #74's cached environment; a gated op reached the phone sheet in 0.8–1.8 s (5.3 s once); Approve on the phone cleared it in the daemon in 2.6–2.8 s; the nextchant runwalked through; chant's ledger names the approver (jhgaylor@gmail.com, not the OS user). Guests are refused (tests in crates/daemon/tests/workspace.rs and web/e2e/workspace.spec.ts). Numbers and what wasn't covered are in PLAN.md's "#74 and M34: as built". Tracker: #86.Shipped in v0.7.0 (tag on
84b5e9b; geek, jake-mini and jake-air upgraded). Tracker: #86.