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.
JavaScript agentic-codingai-agentsai-governanceautonomous-agentsclaude-codeclicode-reviewcodexcoding-agentsdeveloper-toolsgit-hooksllmlocal-firstmulti-agentsoftware-factoryspec-driven-developmentverificationvibe-coding
fix(board): allow fresh worktrees to initialize [A5,A6]
Corey Olsone4f94d3f9813
diff --git a/src/board.js b/src/board.jsindex 7d9cd207..a232f89f 100644--- a/src/board.js+++ b/src/board.js@@ -152,12 +152,12 @@ export function openBoard(file, clock = systemClock, { isMain } = {}) {} finally {current.close();}- }- if (SCHEMA_VERSION > boardVersion) {- throw new Refused(- 'UNMERGED_SCHEMA',- `this worktree expects board schema ${SCHEMA_VERSION}, newer than the shared board's version ${boardVersion}; merge this code into the main checkout first, or test it against a throwaway board`,- );+ if (SCHEMA_VERSION > boardVersion) {+ throw new Refused(+ 'UNMERGED_SCHEMA',+ `this worktree expects board schema ${SCHEMA_VERSION}, newer than the shared board's version ${boardVersion}; merge this code into the main checkout first, or test it against a throwaway board`,+ );+ }}}if (file !== ':memory:') mkdirSync(dirname(file), { recursive: true });diff --git a/test/machine.test.js b/test/machine.test.jsindex 494ec5ff..aca377db 100644--- a/test/machine.test.js+++ b/test/machine.test.js@@ -28,6 +28,7 @@ const NOT_MOVES = {ONE_COORDINATOR: 'registering who is asking, before any move',BAD_MACHINE_SETTINGS: 'machine-wide settings checked before a command runs',BAD_GATE_SLOTS: 'machine-wide gate capacity checked before a command runs',+ UNMERGED_SCHEMA: 'shared-board schema compatibility checked before a command opens the database',};/**@@ -1030,6 +1031,13 @@ test('next --verify reserves the review for the reviewLease and says until when;const commit = git(builder, 'rev-parse', 'HEAD');const submitted = run(builder, 'submit', '1');assert.equal(submitted.status, 0, submitted.stderr);+ const commonDir = git(repo, 'rev-parse', '--path-format=absolute', '--git-common-dir');+ assert.equal(git(holder, 'rev-parse', '--path-format=absolute', '--git-common-dir'), commonDir,+ 'the verifier worktree reads the builder repo common dir');+ const sharedBoard = new DatabaseSync(join(commonDir, 'pullboard', 'board.sqlite'), { readOnly: true });+ assert.equal(sharedBoard.prepare('PRAGMA user_version').get().user_version, 2,+ 'the main repo creates the shared board before the verifier opens it');+ sharedBoard.close();const before = Date.now();const first = run(holder, 'next', '--verify');