diff options
| author | Adam Soltys <[email protected]> | 2026-07-06 07:38:38 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-07-06 07:38:38 -0700 |
| commit | d6da40c92ee8e76708b9230c404688c431f879a0 (patch) | |
| tree | f2df12eb3275a8e5908b788b51e4529fed96fec1 /src/format.js | |
| parent | 7d06c1b7801579da05e919c76a33c2f9b05f995d (diff) | |
| download | coinosv3-d6da40c92ee8e76708b9230c404688c431f879a0.tar.gz coinosv3-d6da40c92ee8e76708b9230c404688c431f879a0.zip | |
Per-device sync slots: devices never share a replaceable event
The clobber was structural: all devices published to one replaceable
event (same seed -> same nostr key -> one slot), so whoever saved last
won and a device saving before it merged wiped the others' coins. Now
each device publishes to its OWN d-tag (<base>:d:<deviceId>, deviceId
random per browser in localStorage), and readers pull ALL of the
identity's kind-30078 events — every device slot plus the legacy shared
tag for migration — merging ark vtxos across all of them and applying
the newest full snapshot for on-chain state. No device can overwrite
another's slot, so anti-entropy is no longer load-bearing (kept as
belt-and-suspenders). Live subscription drops its #d filter to see all
slots; publish and the echo-guard use the per-device tag.
Verified: two same-seed devices produce two distinct relay slots that
coexist, B sees A's funds, both converge after a spend.
Co-Authored-By: Claude Fable 5 <[email protected]>
Diffstat (limited to 'src/format.js')
0 files changed, 0 insertions, 0 deletions
