Skip to content

id(currency): graph↔ledger reconciliation + supply-audit job (from #2062) #2320

Open

Description

@dezren39

Follow-up from the currency control plane design (#2062), §7 of
doc/2026-10-29T12-42-21Z_design_currency_control_plane/.

Scope

The scheduled reconciliation and supply-audit job.

  • Supply audit: sum issuer-account debits per currency vs holders + fee + burn (design §7.3).
  • Resolve each recent transfer's user_data_128 to its signed graph object; report unresolved links (design §7.1–§7.2).
  • Report registry↔ledger↔graph drift to an operator surface; ledger wins on balance, graph is flagged for review.

Acceptance

  • A seeded cluster with a known supply reports a match; an injected divergence is reported with the currency, the ledger id, and the offending object.
  • A transfer whose user_data_128 has no graph object is reported, not silently ignored.

Depends on

F1, F2.

Refs #2062

Activity

  1. added
    kind/featureNew feature or capability request
    source/queue-workerFiled or worked by the queue/worker pilot
    priority/normalOrdinary priority (the default)
    meta/follow-upFollow-up spun out of earlier work
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    effort/mMedium: expected under 1 day of work
    on Oct 29, 2026
  2. developing-today commented on Oct 29, 2026

    @developing-today
    Contributor
  3. added
    meta/enrichedIntake review done: acceptance criteria, links, and normalized labels added
    on Oct 29, 2026
  4. dezren39 commented on Oct 29, 2026

    @dezren39
    MemberAuthor

    Intake review

    Related: #2062 (design §7), #2317/#2318 (F1/F2 dependencies), #2321 (the PoC whose cluster this audits)

    Notes: Graph↔ledger reconciliation + supply-audit job for the currency control plane. The body carries a full ## Acceptance list (seeded match, injected divergence reported with ids, unresolved user_data_128 reported not ignored), so this pass is labels-only.

    Risks: Reconciliation that auto-fixes drift would hide exactly the corruption it exists to surface — the design's rule (ledger wins on balance, graph flagged for review) must hold.

    Suggested approach: Build after F1/F2; implement audit + link resolution as a scheduled job with operator-surface reporting; test with the seeded-divergence case.

    🤖 Agent note · filed

    • Agent: fleet monitor (repo-fleet-monitor)
    • Session / ID: repo-fleet-monitor run 2026-10-29T18:12Z (13:12 CDT)
    • Found via: monitor reconciliation
    • Task: Duty 2 intake enrichment — labels normalized and meta/enriched applied; acceptance criteria appended to the body only where no acceptance section existed (original body preserved verbatim above it). Still-live check this pass: no merged PR or fix commit explicitly resolving this issue was found in this pass's search.
    • Expectation: see the effort label; done = the acceptance criteria are met.
    • Links: this issue
  5. added
    queue/queuedHas a queued task in the Supabase agent queue
    task/triageQueue packet kind: verify, reproduce, and route this item
    on Nov 3, 2026
  6. developing-today commented on Nov 3, 2026

    @developing-today
    Contributor

    agent-note:v1
    state: triaged (coverage pass)
    Coverage pass 2026-11-03: reviewed in the fleet-wide per-issue pass (drift / overlap / already-handled / stale / blockers / ordering). Verdict: still live; queued in repo-health-code-pilot as triage at priority 40 (priority/normal). If this is already handled at current main, the triage closes it with evidence; if it needs splitting, the triage files the split.
    Found via: coverage pass 2026-11-03

  7. 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 3, 2026
  8. dezren39 commented on Nov 3, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · handed off

  9. dezren39 commented on Nov 3, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    state: triaged
    queue: repo-health-code-pilot
    task: 7891 (completed, outcome triaged)
    by: openchamber-scheduled-lane (repo-worker-code, lane bf419306)
    at: 2026-11-03T19:47Z

    Triage at current main: still live, not started. No supply-audit or graph-ledger reconciliation code exists in pkgs/id/src/currency_poc/ (grep of origin/main for supply audit, reconcile, burn, holders finds only the existing intent-recovery reconciler, which is unrelated).
    Blockers (all OPEN): #2317 (F1 registry + ledger-u32 allocator), #2318 (F2 account factory + system accounts), and #2321 (PoC cluster this job audits). The issue's own "Depends on F1, F2" applies.
    Ordering: implement after F1 and F2 land and the PoC (#2321) gives a seedable cluster. Scope as the body states: supply audit per design #2062 §7.3, transfer link resolution §7.1-7.2, and drift report. Acceptance (seeded match, injected divergence, unresolved link reported) stays as written.
    No fix PR opened from triage and no follow-up task. Labels: removed queue/claimed, work/assigned, status/in-progress; added status/blocked (blocked on #2317/#2318/#2321) and status/triaged.

  10. added
    status/blockedQueue or user escalation state
    status/triagedTriaged and routed (see agent note)
    and removed
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    on Nov 3, 2026
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/mMedium: expected under 1 day of workkind/featureNew feature or capability requestmeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedmeta/follow-upFollow-up spun out of earlier workpriority/normalOrdinary priority (the default)source/queue-workerFiled or worked by the queue/worker pilotstatus/blockedQueue or user escalation statestatus/triagedTriaged and routed (see agent note)task/triageQueue packet kind: verify, reproduce, and route this item

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions