notes
All repositories: gitoria
#5Prevent saved local edits from restoring deleted notes
mergednotes17-ghost-note → mainby · head ae1075b2
- successKunibert: kunibertKunibert review
Verdicts
- Kunibertapproved
People’s approvals
Reviews
Kunibertappapprovedae1075b2 · current head · 2026-11-10 11:42:24 UTC
The rejected-draft fix resolves T1 by preserving edits when adopting the server id. No new correctness or standards issues were found.
Correctness (0 new, 0 still open)
T1 is resolved; no remaining correctness findings.
Spec (0 new, 0 still open)
No ticket or issue is linked, so there are no spec findings.
Standards (0 new, 0 still open)
No documented-rule violations found in the changed lines.
Gates: not run
Kunibertapprequested changes383cce23 · earlier head · 2026-11-10 11:15:03 UTC
The ordering change addresses the deletion race but can discard a new note’s rejected draft. The added tests miss this failure path.
Correctness (1 new, 0 still open)
One data-loss issue remains when a rejected save triggers the transition from a local note id to its server id.
Spec (0 new, 0 still open)
No ticket or issue is linked, so there are no spec findings.
Standards (0 new, 0 still open)
No documented-rule violations found in the changed lines.
Gates: not run
Threads
components/notes.hl:343outdated · resolvedKunibert
Conversation
Nobody has written here yet.
Only the owner and the members of this repository can comment here.
Kunibert2026-11-10 11:15:03 UTC
🔶 Major · Correctness: no rule: Retain rejected drafts when adopting the server id
Create an online note and enter over 200,000 characters in Markdown source while its selection still uses the temporary
l…id.pushNoterejects the text, butnotesPutstill emitsnotesChanged;settle()then unconditionally removes the local-key edit when adopting the server id. With this assignment moved before the emit, nothing restores the rejected draft, so changing notes discards it. Preserve or rekey unacknowledged edits during the id transition and cover a rejected save in the regression tests.Kunibert2026-11-10 11:42:25 UTC
Fixed: remaining drafts are rekeyed instead of discarded. The regression covers rejection, reopening the draft, and saving corrected text to the same server id.