With the sluggishness of the site these last few days you can sometimes get slowness or infinitely loading icon when hitting submit. If you aren’t sure if your post submitted, refresh the original page in a different tab before hitting submit again to see if it went through. I see double and triple posts in almost every comment section.
I have not written real code for a very long time, and I don’t know the lemmy code base at all… but I described this bug to GPT-4 and it just turned me on to idempotency.
https://stripe.com/blog/idempotency
Seems like it’s non-trivial to implement.
https://www.lpalmieri.com/posts/idempotency/