How to do a conditional write in spaces? #5432
Replies: 1 comment
|
You're not missing anything: You can see it in the lexicon, which only takes The handler only reads those same fields: The storage layer has a swap check, but nothing can reach it yet. There's a comment saying so ("No space lexicon offers a swap yet"): atproto/packages/pds/src/actor-store/space/transactor.ts Lines 166 to 169 in de009e6 So for now a conditional write has to be done client-side: read the record ( |
Uh oh!
There was an error while loading. Please reload this page.
Im trying out spaces alpha with a simple sync engine for notes that can be updated from more than one device.
I currently have it working on the public API where a conditional write with
com.atproto.repo.putRecordandswapRecordyieldsInvalidSwapif the record's been changed since last read.I tried the same with
com.atproto.space.putRecordwithswapRecordbut it just replaced the record.Am I missing another way to do a conditional write in a space?
All reactions