Our Personal Data Server from scratch! tranquil.farm
pds rust database fun oauth atproto
238
fork

Configure Feed

Select the types of activity you want to include in your feed.

delete + create in the same applyWrites makes com.atproto.repo RPCs behave incorrectly #1

open opened by char.lt

when POSTing to /xrpc/com.atproto.repo.applyWrites with something like

{
  "repo": "did:web:example.com",
  "writes": [
    { "$type": "com.atproto.repo.applyWrites#delete",
      "collection": "com.example.myrecord", "rkey": "3333333333333" },
    { "$type": "com.atproto.repo.applyWrites#create",
      "collection": "com.example.myrecord", "rkey": "3333333333333",
      "value": { "$type": "com.example.myrecord", "hello": "world" } },
  ]
}

the delete and create go out on the event stream in the correct order, so AppViews reflect the write, but the AT-URI of the record is no longer present in com.atproto.repo.listRecords and 404s in com.atproto.repo.getRecord (but a valid carslice is returned from com.atproto.sync.getRecord !) - so com.atproto.repo APIs become out of sync with external views of the repo.

you can test this trivially with PDSls, since it has a "recreate" option in the advanced section of the record editor, which will emit a delete and create instead of an update.

[deleted by author]
[deleted by author]
[deleted by author]
[deleted by author]
sign up or login to add to the discussion
Labels

None yet.

assignee

None yet.

Participants 2
AT URI
at://did:plc:fp5zf7du5zntbwwcxkk3dppd/sh.tangled.repo.issue/3mkaqii4h2n22