persist: Phase 1 — log + kv facets on injectable in-memory backend + 28 tests
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 1m3s
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 1m3s
event/backend/log/kv/api over one injected backend protocol (mem default). log: append/read/read-from, sequential per-stream seq, stream isolation. kv: get/put/delete/has?/keys/get-or/update. conformance.sh + 3 suites, 28/28. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -42,7 +42,7 @@ read models (feeds, indices, audit logs) update incrementally.
|
||||
|
||||
## Status (rolling)
|
||||
|
||||
`bash lib/persist/conformance.sh` → **0/0** (not yet started)
|
||||
`bash lib/persist/conformance.sh` → **28/28** (Phase 1 done)
|
||||
|
||||
## Ground rules
|
||||
|
||||
@@ -87,11 +87,11 @@ lib/persist/backend.sx lib/persist/api.sx
|
||||
```
|
||||
|
||||
## Phase 1 — Log + kv + in-memory backend
|
||||
- [ ] `event.sx` — event record, stream/seq helpers
|
||||
- [ ] `backend.sx` — injectable protocol + in-memory impl (log + kv)
|
||||
- [ ] `log.sx` — `append` (optimistic seq), `read`, `read-from`
|
||||
- [ ] `kv.sx` — `get`/`put`/`delete` current-state
|
||||
- [ ] `api.sx` + tests + scoreboard + conformance.sh
|
||||
- [x] `event.sx` — event record, stream/seq helpers
|
||||
- [x] `backend.sx` — injectable protocol + in-memory impl (log + kv)
|
||||
- [x] `log.sx` — `append` (optimistic seq), `read`, `read-from`
|
||||
- [x] `kv.sx` — `get`/`put`/`delete` current-state
|
||||
- [x] `api.sx` + tests + scoreboard + conformance.sh
|
||||
|
||||
## Phase 2 — Projections + subscriptions
|
||||
- [ ] `project.sx` — `(project stream step seed)`, incremental fold
|
||||
@@ -113,7 +113,19 @@ feed/-log, flow store, mod/audit, search index, acl grants, identity sessions al
|
||||
become `persist` log or kv. Track each migration in that subsystem's plan.
|
||||
|
||||
## Progress log
|
||||
(loop fills this in)
|
||||
- **Phase 1 complete (28/28).** `event.sx` (event record + accessors),
|
||||
`backend.sx` (injectable protocol + in-memory log/kv impl, closure state via
|
||||
set!), `log.sx` (append/read/read-from, sequential per-stream seq, stream
|
||||
isolation), `kv.sx` (get/put/delete/has?/keys/get-or/update), `api.sx`
|
||||
(`persist/open` — mem default, backend injectable). conformance.sh + three
|
||||
suites (event/log/kv). Gotcha logged in Blockers: `map` returns an
|
||||
array-backed list not `equal?` to a `(list ...)` literal — assertions build
|
||||
compared lists with list/nth.
|
||||
|
||||
## Blockers
|
||||
(loop fills this in)
|
||||
- **Not a blocker, a testing convention:** `map` returns an array-backed list
|
||||
that is NOT `equal?` to a `(list ...)` cons-literal (two `map` results do
|
||||
compare equal to each other). When asserting list-shaped results against a
|
||||
`(list ...)` literal, build the compared value with `list`/`nth`/`cons`, not
|
||||
`map`. `into`/list-coercion needs the IO bridge and is unusable in the
|
||||
pure-eval harness.
|
||||
|
||||
Reference in New Issue
Block a user