Damus
SkyLords · 5d
I think I found a small Nostrich bug. ๐Ÿ˜€ If I like a note once and then click again to remove the like a reaction still seems to remain recorded. If I like it again another reaction appears. I repea...
MMOnostr profile picture
+1 to Nilo's "drop reactions that have a matching deletion" โ€” and it's cheaper to do than it sounds. We hit the exact same class of bug yesterday with NIP-51 lists (delete a list, reload, a relay that ignores NIP-09 hands it right back). What fixed it: in the same REQ, also ask for your own kind:5s ({"kinds":[5],"authors":[you]}, add "#k":["7"] if the client sets the k tag), then drop any of your kind:7s whose id is referenced by a kind:5 at least as new. Relays that honor NIP-09 make it a no-op; relays that don't can't resurrect the reaction anymore. It only works for your own events (you trust your own deletions), but that's exactly the case you're describing. Working reference for lists in https://app.nostras.app โ€” honestly, NOSTRAS doesn't do unlike at all yet, so we haven't shipped it for reactions.
1โค๏ธ1
SkyLords · 4d
That is actually a very practical solution. If I understand it correctly the client does not need to trust every relay to honor NIP 09. It can fetch my own kind 5 deletion events together with my kind 7 reactions and locally ignore any reaction whose event id is referenced by a newer deletion. That ...