Skip to content

id: build: stable note identity and revision graph #3814

Closed

Description

@dezren39

Parent: #2048 (ID Zettelkasten design). Phase 1 — foundational, no hard dependency.

Implement the approved #2048 model in pkgs/id: a stable logical note identity, distinct from immutable content-revision event IDs, with append-only signed revisions and explicit causal parent revision IDs. Use blob-backed content snapshots and expose deterministic note history/head state. Concurrent revisions must remain separate heads; an explicit merge revision names the heads it joins. Preserve existing document.put and document.remove behavior for non-note documents.

Scope: core event representation, validation, local event-store fold/history, and focused tests. No editor/UI, full-text or backlink index, shared-write authorization, cross-store resolver, or migration of existing files. Do not add a deletion/erasure API in this phase: #2048 has an open product question about tombstone vs cryptographic erasure, and the current document.remove retains content.

Acceptance:

  • Note ID remains stable across revisions and is not a mutable filename or alias.
  • Every revision is signed, immutable, content-hash verified, and names its note plus causal parent revision(s).
  • Two concurrent revisions produce two deterministic heads; a merge explicitly names both; arrival order does not change history.
  • Existing document event fixtures and public behavior remain compatible.
  • Unit/integration tests cover validation, revision lookup, concurrent heads and explicit merge.

Related inputs: #2047 (friendly names resolve to stable IDs); #2238 (writer-set/view projection is a separate visibility layer). This phase establishes data identity only; it does not decide who may write a shared note.

Activity

  1. added
    priority/highImportant and time-sensitive
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    effort/lLarge: multi-day or open-ended; expect staged check-ins
    on Nov 1, 2026
  2. developing-today commented on Nov 1, 2026

    @developing-today
    Contributor
  3. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    agent-note:v1 — queued, parent #2048 phase 1; queue task 5824, dedupe repo-health:v1:fix:developing-today/code:issue:3814. Resume after claim: implement stable signed note identity/revisions, deterministic heads and explicit merge; deletion policy is explicitly out of scope pending Drew’s Q1 answer. Filed by repo-worker-code, OpenChamber scheduled lane, 2026-11-01T16:54Z.

  4. added
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed
    queue/queuedHas a queued task in the Supabase agent queue
    on Nov 1, 2026
  5. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    agent-note:v1 — holder: repo-worker-code (OpenChamber scheduled lane), status: picked up, task: 5824, at: 2026-11-01T17:02Z. Revalidated #3814 open; no related open PR found. Preparing a dedicated laptop worktree for the foundational note identity/revision implementation; deletion remains explicitly out of scope pending Drew’s Q1 answer.

  6. 27 remaining items

  7. added
    queue/claimedQueue worker lifecycle state
    and removed
    status/parkedDeliberately paused with a recorded resume condition
    queue/parkedQueue task is parked (waiting on CI, time, or an event)
    on Nov 1, 2026
  8. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    Picked up by queue worker lane E (task 5824) — resuming from the parked checkpoint. Fresh revalidation: issue #3814 open, PR #3908 open on branch queue/5824-3814-stable-note-revisions with no hard-stop labels; Codex P1/P2 findings on PR #3908 already fixed in 74ab277 and replied. Remaining step is the verified CodeRabbit finding: include note ID + parent revision IDs from NoteOp::Revise in prune_behind_cut dependencies, plus a regression test.

  9. added a commit that references this issue on Nov 1, 2026
  10. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    Done (task 5824, queue worker lane E): PR #3908 merged as 8540505 — issue #3814 closed. This shift: implemented the outstanding CodeRabbit finding (prune_behind_cut now treats NoteOp::Revise note + parent revision IDs as prune dependencies, commit 1e410fa, with regression test), fixed the E0063 note-field breakage the notes change had left in 13 pkgs/id integration-test files (commit 8a5ccbf; all 12 affected targets compile again), merged current main into the branch (1149ba7, picking up the #3871 voiding fix), and verified on the laptop: retention_pruning 5/5, voiding_scenarios 12/12, documents 5/5, tag_claims 12/12, content_removal 7/7, aliases 12/12, search 13/13, cli_documents 8/8, bridge_poc 7/7. Codex P1/P2 on PR #3908 were fixed in 74ab277 (earlier shift) and replied; CodeRabbit confirmed the prune fix and resolved its thread. Known pre-existing, unrelated: id-core lib-test vt100 compile failure (code#3923) still blocks cargo test --lib for the id crate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/lLarge: multi-day or open-ended; expect staged check-inskind/enhancementpriority/highImportant and time-sensitive

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions