chore(client): retirer la migration legacy + alléger les logs d'accès
- Migration des comptes legacy supprimée (migrateLegacyRecords + garde migratedInto + call-sites). Un wallet pré-fix (records store-root, pas de pointeur) provisionne simplement un doc-shim frais; contenu legacy ignoré (voulu, données = dev). La résolution barrière-autoritative + anti-fork (resolvePointer/ensureRepoOpen/ canonicalDoc/ensureInFlight/pointerGuard) est inchangée. - Logs d'accès SDK préfixés [polyfill] + NURI tronqué via shortNuri() (retire did:ng:o: et :v:…, garde 8 chars) → moins verbeux. Ex: [polyfill] [user1] READ vDlwbZio… (resolvePointer) → 1 triple-rows Tests: bun test unit 126/0. Docs (nextgraph-current-state/simulation/migration-guide) mis à jour (migration legacy retirée du modèle décrit). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -264,9 +264,8 @@ document is both (previous section), the shim uses an **indirection**:
|
||||
named doc-shim through its barrier (`ensureRepoOpen`) → read the account
|
||||
AUTHORITATIVELY. First login (no pointer): `doc_create` the doc-shim, publish the
|
||||
pointer, done. A **pointer fork** (two devices each writing a pointer before either
|
||||
synced) is **benign**: reconcile to the lexicographically-smallest doc-shim NURI
|
||||
(content-addressed, so every device converges), and no account data is lost — a
|
||||
non-canonical doc-shim's records are migrated forward on the next resolve.
|
||||
synced) is reconciled to the lexicographically-smallest doc-shim NURI
|
||||
(content-addressed, so every device converges on the same doc-shim).
|
||||
|
||||
**The account-level retry is GONE.** Before this indirection the shim lived directly
|
||||
in the store-root graph, so an account read had no barrier and a cold 0 was ambiguous;
|
||||
@@ -279,12 +278,12 @@ re-read of the **pointer** itself (`pointerGuard`, one write-once triple): it ca
|
||||
NEVER re-provision or fork an account — at worst it takes a couple extra reads to see
|
||||
a pointer that is still landing.
|
||||
|
||||
**Migration (no existing account lost).** A wallet whose accounts were written under
|
||||
the OLD scheme has its `AccountRecord`s in the store-root graph, not a doc-shim. On
|
||||
resolution, `migrateLegacyRecords` reads that old location best-effort and RE-INSERTS
|
||||
each legacy record into the doc-shim (copy, not move — the store-root copy is left
|
||||
inert), BEFORE any "account absent" conclusion. So a legacy account is READ (and made
|
||||
barrier-authoritative going forward), never re-provisioned into a fork.
|
||||
**No legacy migration.** A wallet written under the OLD scheme (accounts directly in
|
||||
the store-root graph, no pointer) is NOT recovered: opening it under the current scheme
|
||||
simply provisions a fresh doc-shim, and the pre-indirection store-root records are
|
||||
ignored. This is deliberate — the only such wallets are dev data — so the resolution
|
||||
path carries no legacy-migration step; it always reads the account authoritatively from
|
||||
the doc-shim.
|
||||
|
||||
### The union is read-only — writes must target one document
|
||||
|
||||
|
||||
Reference in New Issue
Block a user