Skip to content

Autonomous development for real products. Governed agents build from specs you approve, follow the rules you set, and nothing merges until another agent proves it. Your decisions, judgement and taste are the bar that work must clear. Declare your vision and let agents build it.

Merge main into private board rehome

Corey Olsona75d14863b3b
diff --cc src/cli.js
index de95ccd9,4bd31361..b74ffdef
--- a/src/cli.js
+++ b/src/cli.js
@@@ -1,5 -1,4 +1,6 @@@
+export { resourceRunLabel } from './cli-resource-display.js';
+export { browserAdmissionReporter } from './cli-resource-display.js';
+ import * as personIdentity from './person.js';
import { dependencyValues } from './item-dependencies.js';
import { computedReturnArgs } from './computed-conflict-return.js';
import { ENGINE_VERSION as NATIVE_ENGINE } from './engine-metadata.js';
diff --cc src/person-signing-words.js
index 00000000,2e8b8860..cbcc7604
mode 000000,100644..100644
--- a/src/person-signing-words.js
+++ b/src/person-signing-words.js
@@@ -1,0 -1,7 +1,6 @@@
+ /** One status line about signing: whether person moves are signed, and where they are confirmed. */
+ export function signingLine(signing) {
+ return signing.signed
+ ? 'person moves are signed: each one waits for your passkey on the relay'
+ : 'person moves are not signed; pullboard settings person.signed on makes each one wait for your passkey';
+ }
-
diff --cc src/relay-outbox.js
index c40bd72e,11313c45..4e43eaba
--- a/src/relay-outbox.js
+++ b/src/relay-outbox.js
@@@ -189,10 -182,8 +189,10 @@@ export const ITEM_SLOTS = Object.freeze
recordRowDecisions: [], decideSpecRevisions: [], applyRowDecisions: [], draftSpecRow: [], recordSpecApprovalBaseline: [],
recordLandingBatch: [], recordLandingWaiver: [], recordLandingFlake: [], recordLandingTestDefect: [], finishLandingBatch: [],
recordHealthFindings: [], decideSentinel: [], beginSentinelRun: [], finishSentinelRun: [],
- recordFlakeObservation: [], recordGateRun: [], recordProofRun: [[0, 'itemId'], [0, 'receipt', 'proof', 'item']], declareJob: [], recordJobRun: [], takeCoordinator: [], openHandoff: [], landingLeaseMove: [],
+ recordFlakeObservation: [], recordGateRun: [], recordProofRun: [[0, 'itemId'], [0, 'receipt', 'proof', 'item']], declareJob: [], recordJobRun: [], takeCoordinator: [], openHandoff: [], landingLeaseMove: [], setPersonSigning: [], proposePersonMove: [],
recordActivityDelivery: [], actOnActivity: [], recordRowVerification: [], setBoardMembers: [],
+ // Re-home IDs are acknowledged-only; foreign board/source IDs are never locally rewritten.
+ reserveRehomeItemId: [], rehomeItem: [[0]], applyRehomeItem: [[0, 'destinationItemId']],
...Object.fromEntries(FIRST_ITEM.map((operation) => [operation, [[0]]])),
intakeOutside: [[0, 'item', 'parentId'], [0, 'item', 'after', '*']],
addItem: [[0, 'parentId'], [0, 'after', '*']],
diff --cc test/machine.test.js
index 1f582e78,c0c6aabb..ecfaaede
--- a/test/machine.test.js
+++ b/test/machine.test.js
@@@ -464,11 -475,10 +475,11 @@@ const BROKEN =
];
test('the declared lifecycle is sound: reachable, no traps, no second door, every refusal with a next step [M1, M2, M4]', () => {
- assert.deepEqual(machineProblems(), []);
- assert.deepEqual(MACHINE.states.map((state) => state.id), ['open', 'claimed', 'submitted', 'verified', 'withdrawn']);
- assert.deepEqual(MACHINE.states.filter((state) => state.final).map((state) => state.id), ['withdrawn']);
- assert.deepEqual(MACHINE.moves.map((move) => move.verb), ['rehomeImport', 'intake', 'claim', 'release', 'lapse', 'submit', 'submit-merge', 'reserve', 'accept', 'reject', 'reopen', 'escalate', 'refreeze', 'refreeze', 'withdraw']);
- assert.deepEqual(MACHINE.moves.find((move) => move.verb === 'rehomeImport').sets, ['item_verified_by', 'item_commit']);
+ assert.deepEqual(machineRules.machineProblems(), []);
+ assert.deepEqual(machineRules.MACHINE.states.map((state) => state.id), ['open', 'claimed', 'submitted', 'verified', 'withdrawn']);
+ assert.deepEqual(machineRules.MACHINE.states.filter((state) => state.final).map((state) => state.id), ['withdrawn']);
- assert.deepEqual(machineRules.MACHINE.moves.map((move) => move.verb), ['intake', 'claim', 'release', 'lapse', 'submit', 'submit-merge', 'reserve', 'accept', 'reject', 'reopen', 'escalate', 'refreeze', 'refreeze', 'withdraw']);
++ assert.deepEqual(machineRules.MACHINE.moves.map((move) => move.verb), ['rehomeImport', 'intake', 'claim', 'release', 'lapse', 'submit', 'submit-merge', 'reserve', 'accept', 'reject', 'reopen', 'escalate', 'refreeze', 'refreeze', 'withdraw']);
++ assert.deepEqual(machineRules.MACHINE.moves.find((move) => move.verb === 'rehomeImport').sets, ['item_verified_by', 'item_commit']);
});
for (const broken of BROKEN) {
@@@ -822,22 -830,17 +833,22 @@@ test('an older board gets the triggers
});
test('the triggers come from the declaration, so a changed declaration changes them [M1, M3]', () => {
- const moveSql = (machine) => storeTriggers(machine).find(({ name }) => name === 'machine_item_move').sql;
- const pairs = MACHINE.moves.flatMap((move) => move.from.filter((from) => from !== move.to).map((from) => `'${from}>${move.to}'`));
- for (const pair of pairs) assert.ok(moveSql(MACHINE).includes(pair), `the move trigger allows ${pair}`);
+ const moveSql = (machine) => machineRules.storeTriggers(machine).find(({ name }) => name === 'machine_item_move').sql;
+ const pairs = machineRules.MACHINE.moves.flatMap((move) => move.from.filter((from) => from !== move.to).map((from) => `'${from}>${move.to}'`));
+ for (const pair of pairs) assert.ok(moveSql(machineRules.MACHINE).includes(pair), `the move trigger allows ${pair}`);
- // Intake and a locally proved merge carry are declared; open>verified still has no direct door.
- assert.ok(!moveSql(machineRules.MACHINE).includes("'open>verified'"));
+ // The only open-to-verified edge is the source-acceptance import, not a direct verdict.
- assert.deepEqual(MACHINE.moves.filter((move) => move.from.includes('open') && move.to === 'verified').map((move) => move.verb), ['rehomeImport']);
- assert.ok(moveSql(MACHINE).includes("'open>verified'"));
++ assert.deepEqual(machineRules.MACHINE.moves.filter((move) => move.from.includes('open') && move.to === 'verified').map((move) => move.verb), ['rehomeImport']);
++ assert.ok(moveSql(machineRules.MACHINE).includes("'open>verified'"));
const machine = copy();
- machine.moves.push({ verb: 'testDirectVerdict', from: ['withdrawn'], to: 'verified', by: ['coordinator'], refuse: 'CLOSED', guards: ['joined', 'coordinatorOnly', 'itemExists', IN_STATE], sets: ['item_built_by', 'item_commit', 'item_frozen_digest'] });
- assert.ok(!moveSql(MACHINE).includes("'withdrawn>verified'"));
- machine.moves.push({ verb: 'testDirectVerdict', from: ['open'], to: 'verified', by: ['coordinator'], refuse: 'CLOSED', guards: ['joined', 'coordinatorOnly', 'itemExists', machineRules.IN_STATE], sets: ['item_built_by', 'item_commit', 'item_frozen_digest'] });
- assert.ok(moveSql(machine).includes("'open>verified'"));
++ machine.moves.push({ verb: 'testDirectVerdict', from: ['withdrawn'], to: 'verified', by: ['coordinator'], refuse: 'CLOSED', guards: ['joined', 'coordinatorOnly', 'itemExists', machineRules.IN_STATE], sets: ['item_built_by', 'item_commit', 'item_frozen_digest'] });
++ assert.ok(!moveSql(machineRules.MACHINE).includes("'withdrawn>verified'"));
+ assert.ok(moveSql(machine).includes("'withdrawn>verified'"));
- const names = storeTriggers().map(({ name }) => name);
- for (const state of MACHINE.states.filter((entry) => entry.requires.length)) assert.ok(names.includes(`machine_fields_${state.id}`), `${state.id} has a fields trigger`);
+ const names = machineRules.storeTriggers().map(({ name }) => name);
+ for (const state of machineRules.MACHINE.states.filter((entry) => entry.requires.length)) assert.ok(names.includes(`machine_fields_${state.id}`), `${state.id} has a fields trigger`);
assert.ok(names.includes('machine_proof_verified'));
- const proof = storeTriggers().find(({ name }) => name === 'machine_proof_verified').sql;
++ const proof = machineRules.storeTriggers().find(({ name }) => name === 'machine_proof_verified').sql;
+ assert.match(proof, /AND NOT \(EXISTS[\s\S]+ OR EXISTS[\s\S]+\)\nBEGIN/u,
+ 'the imported proof alternative stays inside the verified proof refusal condition');
});
test("a verified item's proof cannot be rewritten afterwards: its commit, builder, verifier or criterion [M3]", () => {
diff --cc test/relay-parity-operations.js
index 510e2652,ddff65d3..c2157f05
--- a/test/relay-parity-operations.js
+++ b/test/relay-parity-operations.js
@@@ -10,9 -10,9 +10,9 @@@ import { captureSpecApprovalBaseline }
import { loadConfig } from '../src/config.js';
import { decodeBoardKey } from '../src/seal.js';
import { createParityReader, assertReaderParity } from './relay-parity-reader.js';
-import { createStudyExercise, seedStudyState, seedHandoff } from './relay-parity-seeds.js';
+import { createStudyExercise, seedStudyState, seedRehome, seedHandoff } from './relay-parity-seeds.js';
import { submitFixture } from './board-submit-fixture.js';
- import { seedOutside, seedLandingObservations, seedMembership, seedAdministrative, seedBatch, seedCoordinatorAuthority, seedSpecOutcomes, seedBarSignature, seedCurrentOperations } from './relay-parity-extra-seeds.js';
+ import { seedOutside, seedLandingObservations, seedMembership, seedAdministrative, seedBatch, seedCoordinatorAuthority, seedSpecOutcomes, seedBarSignature, seedCurrentOperations, seedPersonSigning } from './relay-parity-extra-seeds.js';
import { syntheticFlakeObservation } from './flake-observation-fixture.js';
/** Run inside the existing private fixture's genuine environment, retaining one HTTP server and person session. */
@@@ -56,8 -56,8 +56,9 @@@ export async function exerciseOperation
await seedCurrentOperations(context);
await seedBarSignature(context);
await seedCoordinatorAuthority(context);
+ await seedRehome(context);
await seedHandoff(context);
+ await seedPersonSigning(context);
const missing = tracking.missing(MOVE_OPERATIONS);
assert.deepEqual(missing, [], `every declared native operation must pass the complete oracle; setup refusals=${JSON.stringify(tracking.setupRefusals)}`);
return { covered: [...tracking.covered].sort(), declared: [...MOVE_OPERATIONS].sort() };
diff --cc test/team.test.js
index 4ca16db1,4cef8385..4a4a3e9c
--- a/test/team.test.js
+++ b/test/team.test.js
@@@ -27,15 -91,9 +91,13 @@@ import
import { ENGINE_VERSION as PEOPLE_VERSION } from '../src/machine.js';
import { relayWorkBudgetMs } from './relay-budget.js';
import { hostname, tmpdir } from 'node:os';
- import { createDeviceKeys, unwrapDeviceBoardKey } from '../src/relay-device-keys.js';
- import { handOverBoardKeys, statementBytes } from '../src/relay-handover.js';
- import { signSshVouch } from '../src/relay-ssh-proof.js';
import { assertMatchingLandingHost, assertNoCulpritTrunkHold } from './landing-environment-fixture.js';
import { landingQueueCase } from './landing-queue-fixture.js';
+import { privateBoardPath } from '../src/projects.js';
+import { checkoutSessionFile } from '../src/agent-session.js';
+import { repoInfo } from '../src/git.js';
+import { privateBoardMoves } from './private-board-move-fixture.js';
+ import { DatabaseSync } from 'node:sqlite';
import {
prepareKeylessInbox,
readKeylessInbox,