Repository navigation
refactor(memory-wiki): reuse canonical plugin normalization - #119449
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed August 4, 2026, 11:20 PM ET / August 5, 2026, 03:20 UTC. ClawSweeper reviewWhat this changesThe PR replaces duplicated Memory Wiki record, string, number, and list normalization with existing public Plugin SDK helpers. Merge readiness⛔ Blocked until real behavior proof from a real setup is added - 3 items remain Keep open for normal maintainer review. The refactor is source-equivalent and uses the intended public Plugin SDK boundary, but the external-PR proof gate still needs an after-fix real behavior artifact. Priority: P3 Review scores
Verification
How this fits togetherMemory Wiki parses ChatGPT exports and Markdown frontmatter, normalizes untrusted values at the plugin boundary, then persists import recovery state and produces wiki summaries. The refactor centralizes that normalization in the public Plugin SDK without changing the import or recovery flows. flowchart LR
A[ChatGPT export and Markdown] --> B[Memory Wiki parsing]
B --> C[Plugin SDK normalization]
C --> D[Import recovery state]
C --> E[Wiki insights and overview]
D --> F[Rollback and recovery]
E --> F
Before merge
Agent review detailsSecurityNone. PR surfaceSource -94. Total -94 across 5 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep the shared SDK normalization path, add a redacted real Memory Wiki import or rollback run showing unchanged output, then complete exact-head maintainer review. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR refactors an existing implementation rather than reporting a user-visible failure; source comparison establishes the intended behavior boundary. Is this the best way to solve the issue? Yes. Reusing already-public canonical Plugin SDK normalization is the narrowest maintainable solution, and direct contract comparison shows it preserves the removed local semantics. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against a8caab5c3d3c. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
What Problem This Solves
The Memory Wiki plugin repeated its own record, optional-string, finite-number, timestamp, and deduplicated-string normalization across ChatGPT imports, persisted import-run recovery state, markdown/frontmatter parsing, import insights, and overview results. Duplicated normalization increased maintenance cost and the risk that these related workflows would drift.
Why This Change Was Made
Reuse the existing canonical public Plugin SDK normalization helpers at the plugin owner boundary and remove redundant local wrappers and repeated normalization work. The change removes 94 production lines (+85/-179 across five files) while preserving ChatGPT export selection, malformed-frontmatter rejection, metadata handling, persisted import-run recovery, rollback ordering, and privacy behavior. It does not change any SQLite schema, vault contract, plugin SDK contract, config/default surface, security boundary, or secret handling.
User Impact
No intended user-visible behavior change: Memory Wiki imports, recovered or rolled-back imports, markdown claims/person cards, insights, and wiki overviews keep their existing outputs and persistence behavior. Operators get the same behavior from less duplicated, consistently normalized plugin code.
Evidence
markdown32,chatgpt-import13,mutation-coordinator4,import-insights2,import-runs1, andwiki-overview1). This includes real SQLite crash/reopen recovery, rollback/retry coordination, and persisting 32 recovery slots before safely handling a 33rd target.pnpm check:changedgate passed on the same isolated trusted Blacksmith Testbox, including production and test extension typechecks, formatting, zero-warning lint, Plugin SDK API/boundary checks, dead-export scans, the database-first storage guard, sidecar checks, and zero runtime import cycles.autoreview --mode local --engine codex --model gpt-5.6-sol --thinking xhigh.Exact-head Memory Wiki import and rollback proof
The actual production importChatGptConversations and rollbackChatGptImportRun owners were executed against a synthetic ChatGPT export, an isolated temporary vault, and a real isolated plugin-state SQLite database at the unchanged reviewed commit. No real user data, operator vault, credentials, or external service was used.
The actual import owner read synthetic conversations.json, wrote an isolated temporary wiki page, and reimported it; the actual rollback owner exercised real SQLite crash/reopen recovery, persisted rollback phases and fences, 33 recovery targets, and symlink safety. Blacksmith run 30972120517 exited 0. This fulfills the requested after-fix import/rollback artifact; a fresh bot review is intentionally not requested because the reviewed commit is unchanged and root policy explicitly requires no re-review round trip for a body-only evidence update.