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.

fix: observe committed local events without another read [C6,N26]

Corey Olsond2dbb45aac77
diff --git a/src/cli.js b/src/cli.js
index ad160fd9..2be0edf5 100644
--- a/src/cli.js
+++ b/src/cli.js
@@ -596,10 +596,9 @@ export async function ordered(ctx, board, operation, args) {
if (initialBaseline && actor) await recordBaseline(actor);
/** Called only for this requested operation, after its store transaction commits, never for bootstrap. */
const applyRequested = () => {
- const before = board.db.prepare('SELECT MAX(event_id) AS id FROM event').get().id ?? 0;
+ const before = board.lastEvent;
const result = store[operation](board, ...args);
- const after = board.db.prepare('SELECT MAX(event_id) AS id FROM event').get().id ?? 0;
- if (after > before) ctx.io.recordedMove = true;
+ if (board.lastEvent !== before) ctx.io.recordedMove = true;
return result;
};
const result = await withItemSession(ctx.info, operation, args, () => relayLinked(ctx.info.root) || relayRecovered(ctx.info.root)