diff --git a/loopx/semantics/project_registry_io_manifest_v1.json b/loopx/semantics/project_registry_io_manifest_v1.json index 4a51d08c9b..af3eabf1d2 100644 --- a/loopx/semantics/project_registry_io_manifest_v1.json +++ b/loopx/semantics/project_registry_io_manifest_v1.json @@ -1535,7 +1535,7 @@ }, { "site": "loopx/history.py::.collect_history::codec_read:load_registry#1", - "line": 301, + "line": 327, "column": 20, "kind": "codec_read", "api": "load_registry", @@ -1543,7 +1543,7 @@ }, { "site": "loopx/history.py::.inspect_index_duplicates::codec_read:load_registry#1", - "line": 542, + "line": 571, "column": 16, "kind": "codec_read", "api": "load_registry", @@ -1551,7 +1551,7 @@ }, { "site": "loopx/history.py::.rebuild_index_artifact_collisions::codec_read:load_registry#1", - "line": 756, + "line": 785, "column": 16, "kind": "codec_read", "api": "load_registry", @@ -1559,7 +1559,7 @@ }, { "site": "loopx/history.py::.repair_index_duplicates::codec_read:load_registry#1", - "line": 646, + "line": 675, "column": 16, "kind": "codec_read", "api": "load_registry", diff --git a/tests/control_plane_ts/deferred_hard_lease_lifecycle.test.ts b/tests/control_plane_ts/deferred_hard_lease_lifecycle.test.ts index 73e1f4c9e5..689dfe48ff 100644 --- a/tests/control_plane_ts/deferred_hard_lease_lifecycle.test.ts +++ b/tests/control_plane_ts/deferred_hard_lease_lifecycle.test.ts @@ -8,6 +8,7 @@ import type {JsonObject} from "../../loopx/control_plane/effect_program.ts"; import {FileAuthorityStore} from "../../loopx/control_plane/coordination/file_authority_store.ts"; import {SqliteAuthorityStore} from "../../loopx/control_plane/coordination/sqlite_authority_store.ts"; import {canonicalAuthoritySha256} from "../../loopx/control_plane/coordination/authority_store_codec.ts"; +import {sqliteAuthorityRuntime} from "../../loopx/control_plane/coordination/sqlite_runtime.ts"; import {TODO_DOMAIN_ITEM_SCHEMA, TODO_DOMAIN_READ_RECORD_SCHEMA, TODO_DOMAIN_RECORD_CONTRACT} from "../../loopx/control_plane/coordination/coordination_state_contract.ts"; import {executeCoordinationTodoUpdate, type CoordinationTodoUpdateInput} from @@ -22,6 +23,12 @@ const TODO = "todo_task"; const OWNER = "agent-a"; const AGENTS = [OWNER, "agent-b"]; +function sqliteSkipReason(): string | undefined { + try { sqliteAuthorityRuntime(); return undefined; } + catch { return "requires a WAL-fixed SQLite runtime with finalized statements"; } +} +const sqliteSkip = sqliteSkipReason(); + async function seeded(provider: "file" | "sqlite", overrides: JsonObject = {}, lease?: JsonObject) { const root = await mkdtemp(join(tmpdir(), `loopx-deferred-${provider}-`)); const path = join(root, "authority"); @@ -72,7 +79,9 @@ function oldLease(status: "active" | "released", expires_at: string): JsonObject } for (const provider of ["file", "sqlite"] as const) { - test(`${provider}: deferred resume is one CAS transition and never grants execution`, async () => { + const skip = provider === "sqlite" ? sqliteSkip : undefined; + + test(`${provider}: deferred resume is one CAS transition and never grants execution`, {skip}, async () => { const store = await seeded(provider); const before = await read(store); assert.equal(leaseOwnerRejection({status: "deferred", claimed_by: OWNER, excluded_agents: []}, OWNER, AGENTS), @@ -99,7 +108,8 @@ for (const provider of ["file", "sqlite"] as const) { "coordination_operation_identity_mismatch"); }); - test(`${provider}: expired lease is retired atomically, while live execution and foreign edits fail closed`, async () => { + test(`${provider}: expired lease is retired atomically, while live execution and foreign edits fail closed`, + {skip}, async () => { const expired = await seeded(provider, {}, oldLease("active", "2026-09-05T22:30:00Z")); const resumed = await executeCoordinationTodoUpdate(expired, resume("retire-expired")); assert.equal(resumed.status, "applied", JSON.stringify(resumed)); @@ -123,7 +133,8 @@ for (const provider of ["file", "sqlite"] as const) { } }); - test(`${provider}: an unclaimed deferred Todo stays unclaimed; excluded actors cannot reopen it`, async () => { + test(`${provider}: an unclaimed deferred Todo stays unclaimed; excluded actors cannot reopen it`, + {skip}, async () => { const unclaimed = await seeded(provider, {claimed_by: null}); const applied = await executeCoordinationTodoUpdate(unclaimed, resume("unclaimed-resume")); assert.equal(applied.status, "applied", JSON.stringify(applied)); @@ -138,7 +149,7 @@ for (const provider of ["file", "sqlite"] as const) { assert.deepEqual(await read(excluded), before); }); - test(`${provider}: deferred supersede closes one Todo and retires expired lease lineage`, async () => { + test(`${provider}: deferred supersede closes one Todo and retires expired lease lineage`, {skip}, async () => { const store = await seeded(provider, {}, oldLease("active", "2026-09-05T22:30:00Z")); const input = supersede("supersede-once"); const before = await read(store);