Skip to content
An aerial view of a braided river, many channels running between green marshy islands before rejoining downstream.
"Aerial shot of braided river channel" by NPS Photo, public domain, via Wikimedia Commons. Cropped to 3:2.

With sync on, apps mostly behave, and that holds for the case where edits arrive one after another. What happens when the order breaks is not written anywhere in the settings screen: you fix a note on a phone in airplane mode during a train journey, you tidy the same note on the desktop, both of you touched the same line, and when the tunnel ends two versions reach the server at once. One wins. The question is which, and on what grounds.

Three strategies, three different costs

The first is last write wins. Easy to build, easy to explain, and it loses data quietly: the paragraph you typed on the phone is erased as though it never existed, because the desktop version landed a second later. Nothing is logged. By the time you notice, there is nothing left to restore.

The second produces a conflict copy. The app keeps both versions and hands you a second record labelled something like “your note (conflict)”; nothing is lost, but the merge becomes your job, and once fifty conflict copies have piled up that job does not get done.

The third merges field by field, or character by character. If the two devices touched different paragraphs both survive, and where they touched the same sentence a deterministic rule decides. This gives the best outcome. It also makes the data structure heavier, the files larger, and exporting to plain Markdown harder.

The clock is a poor referee

The word “last” in “last write wins” comes from the device’s clock, and that clock is not dependable. Phones and laptops drift from each other by seconds and sometimes by minutes; daylight-saving transitions and time-zone changes widen the gap further.

The result is this: a new edit made on the device whose clock runs behind gets overwritten by an older version from the device whose clock runs ahead. The ordering inverts. The app has no idea it did something wrong, because that stamp was the only measure it had.

Serious systems avoid wall-clock time for exactly this reason and use logical counters instead: each device increments its own counter, comparison happens on counters, and the time zone stops mattering at all.

Delete conflicts are their own class

You delete a note on one device and edit that same note on another. Should the delete win, or the edit? Both answers can be defended, and the one a product picks says a lot about its character.

Most systems let the edit win, because restoring a note that was deleted by accident costs more work than deleting a note that came back by accident. In systems that choose the opposite, a deleted note reappears on its own when the second device syncs, and from the outside that looks like a haunting.

Where Context stands today

Sync here ships switched off, and in a workspace that stays on one device the conflict event never happens. That is a postponement rather than a solution. Version 0.4 is not a stable release and the data format is still moving; collaboration sits outside this product’s model, so two people writing one note at the same time is not a scenario being aimed at.

Once you do turn sync on, two habits are worth building. Both are simple.

Close the tab when you leave a device. A tab left open in the background will try, hours later, to push an edit you have forgotten about, and most conflicts start there.

Wait for a sync to finish before splitting a long piece of writing. When the indicator goes green the other device is on the same ground, and the chance of two places touching one line disappears.

All posts

GETTING STARTED

Open it in your browser now.

The web version is live and it is the whole thing — not a cut-down trial copy. If it isn't for you, close the tab and nothing is left behind.

  • No account needed
  • No card asked for
  • 14-day trial on your first purchase