Repository navigation
feat(pm-stack): agg_identity_sessions P1 contract for #1744 Move 1 step 2 - #17045
Conversation
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
|
Remote verification (run 46338415806, job log read firsthand): Turso suite |
|
🤖 Agent note · lane 0640-IE (Felix) — claiming the PR #17045 rebase. PR #17042 (the sibling #1744 feed contract) has merged, leaving this PR CONFLICTING on the adjacent README/plan/test-migration.sh hunks, exactly as 0640-HN's merger note predicted. I will rebase |
…ep 2 (lane 0640-HN)
…ep 2 (lane 0640-HN)
…ep 2 (lane 0640-HN)
…ep 2 (lane 0640-HN)
…ep 2 (lane 0640-HN)
…ep 2 (lane 0640-HN)
…ep 2 (lane 0640-HN)
f15dc72 to
f0e7b28
Compare
|
🤖 Agent note · lane 0640-IE (Felix) — PR #17045 REBASED onto current main and re-verified; merge-ready for Felix.
|
Lane 0640-HN (Felix, 2026-11-29). The last remaining P1 schema contract for #1744, in the established pattern (1452-E: #16975/#16978; 1522-F: #16983; 1607-I: #17003, #17008, #17009; 0640-HN: #17042).
What: P1 schema contract for the identity-registry group — the aggregator's session identity registry (deployed as
identity-registry.json; store contract inaggregator/src/registry.ts, record shapeSessionRecordinaggregator/src/model.ts, merge inaggregator/src/sources/live.ts) →public.agg_identity_sessionsas migration20261129_0008_agg_identity_registry: paired up/down (down refuses non-empty), Turso golden generated by the repo translator, both migration test suites extended (2 new Turso constraint tests; PG suite section mirroring the coverage section), README + migration plan updated. With this and #17042 (feed), everyagg_*group named in the shared-schema map carries a vetted contract.Contract notes: identity is the (source, id) pair the merge keys on, so that pair is the primary key. The reader's gates become checks where the database can state them: the source list is the
RegistrySourcetype (session sources pluscron), provenance is theRegistryProvenancepair and stays nullable (pre-migration records carry none),tokens_totalis finite and non-negative when present.parent_idis deliberately not a foreign key — the registry is loose v1 by design and a record's parent may never land in the registry. Task refs ride as atext[]under the seen-ids precedent (20261116_0001); ref validity (parseRef) stays a validator rule. Records merge in place and are never deleted (the durable identity history outlives the feed attention window), so grants are SELECT/INSERT/UPDATE with no DELETE.Schema-only: no rows copied, no writer/reader cutover; the registry file remains the live backend and rollback target; #1744 criterion 3 untouched.
Merge note for Felix: this branch is independent of #17042 (feed, migration 0007) off a slightly newer main; the README/plan/test-migration.sh hunks sit adjacent to #17042's, so whichever merges second needs a small rebase (in test-migration.sh this branch's vars are pre-named up11/down11 for that). After both land, the two "remaining contract" sentences (each naming the other group) want a one-line reconciliation.
Verification: full
test_turso_migrations.pysuite run against this exact tree = 58 tests OK (56 at base + 2 new registry tests; golden pin for 0008; all pre-existing goldens byte-identical).test-migration.shbash-syntax checked; its disposable-PostgreSQL run is CI's leg, as with prior slices. A remote fleet-command verification run against this branch is dispatched alongside this PR; its verdict will be posted on #1744.Refs #1744
{ "direct_parent": null, "links": [], "lineage": { "design": null, "roadmap_item": null, "priority": null }, "pm_meta": 1, "provenance": { "queue_id": null, "scheduled_start": null, "picked_up_at": null, "work_started_at": null, "created_at": "2026-11-30T02:01:50Z", "session_id": null, "lane": null, "host": "htch-runtime", "worktree": "/home/hatch", "model": null, "lane_start_issues": [], "workspace_ref": { "kind": "worktree", "id": "/home/hatch", "repo": "developing-today/code", "branch": "main", "sha": "010b47d1c4cecdcd1b7d6ea260b7c9b0a61fb89e" }, "auth_subject": "felix", "stamped_by": "fleet 0.1.0 (native)" } }Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.