|
1 | 1 | # 92-gap-backlog |
2 | 2 |
|
3 | | -> Last updated: 2025-12-23 (Post-Round 69: Backlog organized, parity complete) |
| 3 | +> Last updated: 2025-12-25 (Post-Round 73: P0 sync bug FIXED, sync works) |
4 | 4 |
|
5 | 5 | ## Status |
6 | 6 |
|
7 | 7 | - **BUILD: ✅ PASSING** — compiles successfully |
8 | 8 | - **MVP: ✅ PASSING** — all core tests pass |
| 9 | +- **SYNC: ✅ WORKING** — Round 73 fixed critical INSERT INTO crsql_changes bug |
9 | 10 | - Oracle parity: ✅ **18/18 PASSING** |
10 | 11 | - Cross-open parity: ✅ **24/24 PASSING** |
11 | 12 | - rows_impacted: ✅ **18/18 PASSING** |
|
15 | 16 | - Sentinel parity: ✅ **6/6 PASSING** (Round 63) |
16 | 17 | - Multinode sync: ✅ **6/6 PASSING** (Round 63) |
17 | 18 | - Schema mismatch: ⚠️ **11/12 PASSING** (1 divergence: unknown column behavior) |
18 | | -- Savepoint sync: ✅ **16/16 PASSING** (Round 67 — TASK-181 fixed) |
| 19 | +- Savepoint sync: ✅ **16/16 PASSING** (Round 67) |
19 | 20 | - ATTACH CRR: ✅ **15/15 PASSING** (Round 66) |
20 | 21 | - Site ID collision: ✅ **13/13 PASSING** (Round 66) |
21 | 22 | - Trigger CRR: ✅ **31/31 PASSING** (Round 67) |
22 | 23 | - VACUUM CRR: ✅ **17/17 PASSING** (Round 68) |
23 | | -- Wide table: ✅ **13/13 PASSING** (Round 69 — 64-col limit FIXED) |
24 | | -- Test scripts: **63 total** |
| 24 | +- Wide table: ✅ **13/13 PASSING** (Round 69) |
| 25 | +- **App simulation (Todo)**: ✅ **2/2 PASSING** (Round 73) |
| 26 | +- **App simulation (Chat)**: ✅ **4/4 PASSING** (Round 73) |
| 27 | +- **Stress test (60 iterations)**: ✅ **60/60 PASSING, 0 divergences** (Round 73) |
| 28 | +- Parity suite: **357 passed, 13 failed (pre-existing), 22 skipped** |
| 29 | +- Test scripts: **65+ total** |
25 | 30 | - Zig implementation: `zig/` |
26 | 31 | - Canonical task queue: `.tasks/{backlog,active,done}/` |
27 | 32 |
|
28 | 33 | ## Now (next parallel assignments) |
29 | 34 |
|
30 | | -### Backlog: Empty (all parity work complete) |
31 | | - |
32 | | -No tasks ready to delegate. The Zig implementation has reached functional parity with the Rust/C oracle. |
33 | | - |
34 | | -### Pending Decisions (1 item) |
35 | | -| Task | Summary | Blocker | |
36 | | -|------|---------|---------| |
37 | | -| **TASK-186** | Schema mismatch: unknown column behavior | Design decision needed | |
38 | | - |
39 | | -Current divergence (intentional, not a bug): |
40 | | -- **Zig**: ERROR on unknown columns (strict) |
41 | | -- **Rust/C**: IGNORE unknown columns (lenient) |
42 | | - |
43 | | -Options: |
44 | | -1. Align with Rust/C (ignore) — maximizes forward compatibility |
45 | | -2. Keep strict (error) — catches schema drift early |
46 | | -3. Make configurable — `crsql_config_set('ignore-unknown-columns', 1)` |
47 | | - |
48 | | -### Triage Inbox (organized by priority) |
49 | | - |
50 | | -#### LOW Priority — Nice to Have |
51 | | -| Task | Summary | Risk | Effort | |
52 | | -|------|---------|------|--------| |
53 | | -| **TASK-156** | Linux CI parity | CI only | Medium | |
| 35 | +### Active (0 tasks) |
| 36 | +No active tasks. Core sync functionality is complete and working. |
| 37 | + |
| 38 | +### Backlog (4 tasks) |
| 39 | +| Task | Priority | Summary | Effort | |
| 40 | +|------|----------|---------|--------| |
| 41 | +| **TASK-207** | BLOCKED | Re-enable CI for release | Medium (blocked on release decision) | |
| 42 | +| **TASK-186** | MEDIUM | Schema mismatch: unknown column behavior | Design decision | |
| 43 | +| **TASK-204** | LOW | Fix PK UPDATE test schema mismatch | Quick fix | |
| 44 | +| **TASK-205** | LOW | Fix inventory app test | Quick fix | |
| 45 | + |
| 46 | +### Triage Inbox (5 items) |
| 47 | +| Task | Priority | Summary | Disposition | |
| 48 | +|------|----------|---------|-------------| |
| 49 | +| **TASK-191** | HIGH | Port Python Hypothesis tests | Valuable for edge cases | |
| 50 | +| **TASK-199** | MEDIUM | seq divergence (Zig=1, Rust=0) | Needs design decision | |
| 51 | +| **TASK-200** | LOW | Zig validation gaps (more permissive) | Nice to have | |
| 52 | +| **TASK-201** | LOW | Performance regression tests | Nice to have | |
| 53 | +| **TASK-203** | LOW | Empty blob PK encoding divergence | Edge case | |
| 54 | + |
| 55 | +### Blocked on Tom |
| 56 | +| Item | Summary | |
| 57 | +|------|---------| |
| 58 | +| **release-readiness-decision.md** | When are we ready for first public release? | |
54 | 59 |
|
55 | 60 | ### Known Limitations |
56 | 61 | - **crsql_changes SELECT perf**: ~2-7x slower on wide tables vs Rust/C (COUNT is fast, SELECT * is slow) |
| 62 | +- **seq divergence**: Zig starts seq at 1, Rust/C at 0 (doesn't affect sync correctness) |
| 63 | + |
| 64 | +### Completed Round 73 (2025-12-25) — P0 SYNC BUG FIXED |
| 65 | +- [x] **TASK-202**: Fix INSERT INTO crsql_changes failure ✓ (P0 CRITICAL) |
| 66 | + - Root cause: Merge functions only supported INTEGER PKs, TEXT/BLOB PKs failed |
| 67 | + - Fix: Added TEXT/BLOB PK binding, changed to subquery lookups via pks table |
| 68 | + - Files: `zig/src/merge_insert.zig`, `zig/src/changes_vtab.zig` |
| 69 | +- [x] **TASK-198**: Fix db_version off-by-one divergence ✓ |
| 70 | + - Root cause: `pending_db_version` not using `-1` sentinel for uninitialized |
| 71 | + - Fix: Changed initial values to `-1`, unconditional commit, re-read on access |
| 72 | + - Files: `zig/src/site_identity.zig`, `zig/src/local_writes/after_write.zig` |
| 73 | + |
| 74 | +**Key outcome**: Cross-device sync now works! The core cr-sqlite functionality is complete. |
57 | 75 |
|
58 | 76 | ### Completed Round 69 (2025-12-23) |
59 | 77 | - [x] TASK-189: Fix 64-column limit bug ✓ (MAX_COLUMNS increased to 2000, 100+ columns now work) |
|
0 commit comments