GeezerVison is showing github.com — Turso workload adapter and sync state capture · Issue #10165 · developing-today/code
Turso workload adapter and sync state capture #10165DescriptionProblem and goal
Implement local Turso operations and report local revision/push/pull/network state separately from query timing.
Version and design basis
Version: V2. Settled design: https://github.com/developing-today/code/blob/main/doc/2026-11-13T03-40-00Z_design_id-atlas-summit/part-c/versioned-design.md#9133-benchmark-contract-s21s23-s216 (section: #9133 benchmark contract (S2.1–S2.3, S2.16)).
Tier: recommended.
Statement IDs: S2.1, S2.2, S2.3, S2.16
Enables: Turso local measurement
Scope and ownership
Parent: #9133 (native component/meta parent).
pkgs/id/benchmarks/src/adapters/turso.rs (new; owner: C9133-02-turso)
pkgs/id/benchmarks/tests/turso_adapter.rs (new; owner: C9133-02-turso)
Hard dependencies (native blockers): C9133-01 — benchmark crate manifest, schema, shared workload types and synthetic fixtures
Soft sequencing (not blockers): none
Test / evidence first
Create or validate pkgs/id/benchmarks/tests/turso_adapter.rs first. Proposed command: cargo test --manifest-path pkgs/id/benchmarks/Cargo.toml --test turso_adapter
Oracle: reference — expected Local fixture returns same logical rows and exposes sync revision/push/pull separately; test uses no remote credentials.; verifier: Independent reference-store fixture and pinned local database state..
Done and rollback
Done when the declared oracle passes and test/evidence output plus changed-file summary is attached. Research evidence: not applicable.
Rollback: Remove Turso benchmark adapter; no remote database state is changed.
Manifest SHA-256 approval binding: 3b5bce3523945bf5adaa28739f0b90b7b70ff1d6522b4ac827246654e8ff6b06.
Activitydeveloping-today commented on Nov 14, 2026 dezren39 commented on Nov 14, 2026
Agent note — task 17015 preflight recorded (lane any-a): C9133-02-turso native blocker #10153 OPEN — task self-blocked
Native-blocker preflight (fresh, 2026-11-14T17:16Z):
Result: the blocker gate is NOT clear. Per the packet's mandatory preflight instruction, no implementation was performed and task 17015 is self-blocked as a broker dependency block on #10153; the broker returns it to the pool automatically when #10153 closes, and the preflight then re-runs fresh. dezren39 commented on Nov 17, 2026
🤖 Agent note · triaged — task 19124 (lane code-c)
- Work kind: task/small-fix · Priority: priority/high (priorities brief line 2: the ID programme's design/benchmark tracks are Drew's standing explicit priority order; parent research(atlas): benchmark harness — D1 vs R2 vs laptop redb vs laptop Turso, shards x growth #9133 is in the programme's Now wave and its blocker Benchmark schema and synthetic mapping oracle #10153 already carries priority/high) · Effort: effort/m
- Fresh evidence: issue Turso workload adapter and sync state capture #10165 OPEN, unheld. This bulk-intake triage duplicates an already-routed slice: task 17015 owns Turso workload adapter and sync state capture #10165 (slice C9133-02-turso, parent research(atlas): benchmark harness — D1 vs R2 vs laptop redb vs laptop Turso, shards x growth #9133, programme epic: ID/Atlas extensible primitives, federation, namespaces — major design iteration (2026-11-12 directive) #9106) and self-blocked on its single native blocker at preflight on 2026-11-14 (note on this issue). No second packet is enqueued and no second block is recorded.
- Gate re-verification (fresh, this shift, 2026-11-17): the native blocker, issue Benchmark schema and synthetic mapping oracle #10153 (C9133-01 — benchmark schema and synthetic mapping oracle: crate manifest, schema, shared workload types, synthetic fixtures), is still OPEN (currently parked in its own lane posture, priority/high) — NOT CLEAR. Parent research(atlas): benchmark harness — D1 vs R2 vs laptop redb vs laptop Turso, shards x growth #9133 is OPEN.
- First concrete step (unchanged, on task 17015): when Benchmark schema and synthetic mapping oracle #10153 closes, implement
pkgs/id/benchmarks/src/adapters/turso.rs + pkgs/id/benchmarks/tests/turso_adapter.rs test-first, per the slice's declared oracle (reference: local fixture returns the same logical rows and exposes sync revision/push/pull separately from query timing; no remote credentials).
- Labels: this note adds only task/small-fix, priority/high and effort/m. The existing status/blocked + queue/blocked + work/assigned labels belong to task 17015's live blocked state and are deliberately left untouched.
dezren39 commented on Nov 17, 2026
Agent note — preflight triage (lane any-j, task 17015)
State: triaged — preflight confirms a fully specified granular slice (C9133-02-turso) from the #9106 ID/Atlas mill, already routed and dep-blocked under its own task (status/blocked + queue/blocked, left untouched by this preflight). Its triage labels are already set (task/small-fix, priority/high, effort/m).
Fresh evidence (checked 2026-11-17):
- Issue Turso workload adapter and sync state capture #10165 is OPEN; no held / user/owned / do-not-merge / do-not-auto-edit labels.
- The body specifies the slice completely: goal (local Turso operations, reporting local revision/push/pull/network state separately from query timing); settled design basis (part-c versioned design, research(atlas): benchmark harness — D1 vs R2 vs laptop redb vs laptop Turso, shards x growth #9133 benchmark contract S2.1–S2.3/S2.16, V2, tier recommended); owned files (pkgs/id/benchmarks/src/adapters/turso.rs + tests/turso_adapter.rs, both new); a named oracle (reference: local fixture returns the same logical rows and exposes sync revision/push/pull separately; no remote credentials; exact cargo test command given); and a rollback that removes the adapter and changes no remote database state.
- Hard dependency recorded in the body: C9133-01 (benchmark crate manifest, schema, shared workload types, synthetic fixtures). Parent: research(atlas): benchmark harness — D1 vs R2 vs laptop redb vs laptop Turso, shards x growth #9133. The dep-block is consistent with C9133-01 still being open.
Preflight verdict:
- Work kind: task/small-fix (benchmark adapter slice) — already labeled; the slice IS the packet.
- Priority/effort: priority/high + effort/m — already set and correct for the ID benchmark track.
- First concrete step for the claiming lane: re-check C9133-01 fresh, then create the adapter test first per the body's test-first rule.
- Acceptance check for this preflight: this note + the slice spec + its recorded dependency; task 17015 completes as
triaged.
Queue: task 17015 (lane any-j) — claimed, triaged inline per runbook §1c. dezren39 commented on Nov 18, 2026 agent-note:v1
lane: openchamber-scheduled-lane (code-g) · worker repo-worker-code · queue task 20493
kind: triage → blocked
Fresh check 2026-11-18: #10165 OPEN. Its hard dependency is C9133-01 (benchmark crate manifest, schema, shared workload types, synthetic fixtures). I could not find a separate open issue titled C9133-01; parent #9133 is OPEN. The crate-compile fix #11178 is CLOSED. Blocked until the C9133-01 slice is confirmed merged. Resolve the native blocker reference before re-dispatch. dezren39 commented on Nov 23, 2026 Block lifted — blocker sweep 2026-11-23 (Survey A).
Named native blocker for this slice (C9133-02-turso preflight): #10153 (C9133-01 — benchmark schema and synthetic mapping oracle).
Evidence it is now CLOSED (verified fresh via gh REST this pass): #10153 — CLOSED 2026-11-17. It was the sole blocker named in the preflight notes on this issue.
The dependency block is stale, so it is lifted: label queue/blocked removed, queue/queued added. The Turso adapter work itself is not done — it returns to the queue for its approved scope. dezren39 commented on Nov 23, 2026
Claim — Lane OH (archer), 2026-11-23. Taking the C9133-02-turso implementation slice: new pkgs/id/benchmarks/src/adapters/turso.rs + pkgs/id/benchmarks/tests/turso_adapter.rs — local Turso operations reporting local revision/push/pull/network state separately from query timing. Native blocker C9133-01 (#10153) verified CLOSED. Oracle: reference — local fixture returns the same logical rows and exposes sync revision/push/pull separately; no remote credentials. Proposed check: cargo test --manifest-path pkgs/id/benchmarks/Cargo.toml --test turso_adapter. dezren39 commented on Nov 23, 2026
Hold — Lane OH (archer), 2026-11-23. Creating the laptop worktree ~/wt-lane-oh-10165 (branch lane-oh-10165, at exact main SHA 3a941eff430e4bb158e8f2140dd17f8604a43568) returned a result that failed a platform execution-risk check on the checkout's content. Per the standing rule for this flag class, I ran no git/build/test operations inside the worktree afterward and left it untouched at the base SHA. No code landed; no PR opened.
Prepared scope (from this issue's own spec; minutes-to-hours once approved): premise verified TRUE and unclaimed before the flag — issue OPEN, native blocker C9133-01 (#10153) CLOSED, block lifted by the 2026-11-23 sweep. On Drew's item-specific go-ahead for executing in ~/wt-lane-oh-10165, the remaining work is exactly the declared slice:
- New
pkgs/id/benchmarks/src/adapters/turso.rs: local Turso operations against the C9133-01 benchmark crate's shared workload types/fixtures, reporting local revision/push/pull/network state separately from query timing.
- New
pkgs/id/benchmarks/tests/turso_adapter.rs: reference-oracle test — local fixture returns the same logical rows as the reference store and exposes sync revision/push/pull separately; no remote credentials.
- Verify:
cargo test --manifest-path pkgs/id/benchmarks/Cargo.toml --test turso_adapter (in the pkgs/id nix develop shell), then PR + merge, with the test output attached here as the done evidence.
Add code#10165 to the flag-hold list (worktree ~/wt-lane-oh-10165). dezren39 commented on Nov 23, 2026
Takeover claim — Lane YF (archer), 2026-11-23. Adopting Lane OH's orphaned claim on this issue (OH's claim c.7095873330 and hold record c.7095899301; OH went silent after the platform execution-risk flag fired on worktree creation). Drew approved this item in the 2026-11-23 07:35 CST batch approval of the former flag holds.
First-hand state check: worktree ~/wt-lane-oh-10165 (branch lane-oh-10165) is exactly as the hold record left it — HEAD at base SHA 3a941eff430e4bb158e8f2140dd17f8604a43568, clean status, no implementation present. I will implement the declared slice in that worktree:
- New
pkgs/id/benchmarks/src/adapters/turso.rs — local Turso operations against the C9133-01 benchmark crate's shared workload types/fixtures, reporting local revision/push/pull/network state separately from query timing.
- New
pkgs/id/benchmarks/tests/turso_adapter.rs — reference-oracle test: local fixture returns the same logical rows as the reference store and exposes sync revision/push/pull separately; no remote credentials.
- Verify:
cargo test --manifest-path pkgs/id/benchmarks/Cargo.toml --test turso_adapter (pkgs/id nix develop shell), then PR + merge, with test output attached as done evidence per the issue's Done criteria.
dezren39 commented on Nov 23, 2026
Done — Lane YF (archer), 2026-11-23. Slice C9133-02-turso landed under Drew's 2026-11-23 batch approval, adopting Lane OH's orphaned claim (c.7095873330) and prepared scope (hold record c.7095899301). OH's worktree was verified first-hand to be exactly as the hold record left it (base SHA 3a941eff430e, clean, no implementation), so the slice was implemented fresh in it.
Landed: PR #13380 merged — merge commit 28bfc25e454f918ec1261351f97c922414c853fe, head SHA-guarded at d33a4f35ea5. Adapter confirmed on main (blob cd60cf87e775).
Changed files (+805):
pkgs/id/benchmarks/src/adapters/turso.rs (new) — local Turso operations over a SQLite-format database file via rusqlite =0.42.0 bundled (the pkgs/id workspace pin); single-transaction puts/authority transitions, indexed selects, parameterized scan; sync state (local_revision / pushed_revision / pulled_revision / pending_push_revisions / network = local-only) captured in a sync_state table inside the same transaction as each mutation and reported separately from every transition. No remote endpoint, no network calls, no credentials.
pkgs/id/benchmarks/tests/turso_adapter.rs (new) — the declared reference oracle plus the per-step sync fixture and a reopen-persistence test.
pkgs/id/benchmarks/src/adapters/mod.rs — pub mod turso; wiring.
pkgs/id/benchmarks/Cargo.toml — the rusqlite dependency.
Evidence (the issue's declared oracle): cargo test --manifest-path pkgs/id/benchmarks/Cargo.toml --test turso_adapter, run on the laptop in the pkgs/id nix develop shell at the merged head:
running 2 tests
test turso_adapter_persists_across_reopen ... ok
test turso_adapter_matches_reference_oracle_and_sync_fixture ... ok
test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
All 16 fixture transitions equal the fixture's expected rows and the C9133-01 reference store's transitions; every plan Turso cell maps to the fixture's recorded support level; the local revision after each step matches the pinned sequence 1,1,1,1,1,2,2,2,3,4,4,4,5,6,7,7 (reads and refused/no-change operations never advance it), with pushed/pulled at 0 throughout. Full crate suite at the same head: d1_adapter 2 passed, r2_adapter 6 passed, redb_adapter 2 passed, turso_adapter 2 passed, workload_oracle 2 passed; rustfmt clean.
Verifying-route note: a remote dispatch of the same command ran first (dezren39/fleet run 45192549416) and failed before any test executed — the fleet-build container's nix develop is broken (nix-command experimental feature disabled, the #13159 family) — so the laptop run above is the verifying route of record. Two environment facts from the laptop run: the shared sccache server stalled under multi-lane load, so the passing build ran with RUSTC_WRAPPER disabled; the crate's generated Cargo.lock was left untracked, matching this crate's prior convention.
Closing as completed: the declared oracle passes and the test output + changed-file summary are attached here, per this issue's Done criteria.
MetadataMetadataDevelopmentNo branches or pull requestsIssue actions
|