Append/prepend to a note body without replacing it #7
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Filed from
halfst/mpx-engine#116 / #120. This one has already caused a near-miss.What's needed
A way to add text to a note body without supplying the whole body —
appendandprependparameters onticktick-update-note, or dedicated tools.Today
update-note'scontentparameter replaces the entire body. Any additive edit requires reading the current body, concatenating, and writing it all back.Why that read-modify-write is dangerous here
The obvious workaround is unsafe in this specific server because of how the read side behaves.
ticktick-list-notesis documented as subject to a whole-response size budget and can return truncatedcontent. So the natural sequence — list notes, append a line, write back — silently replaces a full note with a truncated one plus your addition.That is not theoretical. It is exactly what happened in
halfst/mpx-engine#81, and decision 2 (comment 1887) removed TickTick write-back from the note sweep entirely rather than risk it:The capability that got dropped as a result — visibly marking a swept Inbox note — is still unbuilt (#116). An append primitive would have made it a two-line change.
Where it's needed next
Sync Operating Spec§4.3, the Done-column archive:"Prepend a bullet, newest first" against a card that accumulates history is precisely the operation that must not be done by round-tripping a possibly-truncated body.
Acceptance
kind: NOTEobjects.Unblocks
halfst/mpx-engine#116 (marking swept Inbox notes, if a marker is still wanted once deletion lands) and Sync Spec §4.3's Archive card prepend.