YSK: Hitting submit more than once will post your comment/thread multiple times, even with the lag

WontonSoup@lemmy.world to You Should Know@lemmy.world – 695 points –

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.

87

if only I had known this earlier

I mean you have 2 comments total including this one, it isn't really too late ;)

Another great bastion of reddit content has been felled.

Another reason for redditors to leave and join Lemmy

People are forgetting that a lot of these Lemmy servers are being run by just a couple people, sometimes with a server in their basement lol

This is especially bad on really popular instances like lemmy.world. It seems the server can't keep up with all the requests or something along those lines.

Some of the apps like Memmy throw an error and then leave you back at the comment screen. Most people probably try again because the comment and submit button is right there.

What they don’t realize is that despite the error, most times the server has accepted the comment.

Don’t get me wrong, I love Memmy (it’s been my primary driver) but this one error combined with poor performance of the lemmy.world instance (also not their fault, growing pains are a good problem to have! Hopefully not for too long….) is probably a significant contributor to this issue since many people probably don’t realize what the error means since it only says “syntax error: JSON Parse Error - unexpected token ‘<‘“ which doesn’t mean anything if you don’t speak nerd.

(For anyone who might wonder: if you are expecting json data which looks {“like”:”this”,”with”:”curly braces”} and instead you get a 500 Server Error web page which is an <html><body>Because the server is sending an error explain for a human to read displayed in browser</body></html> then your program gets confused why there is a < at the start instead of a { and now maybe the error text seems a bit less cryptic)

EDIT: Good lord, the irony

Is there a way to load balance these lemmy instances across multiple backend servers?

Yes, and I think they are.

Backend sizes likely need to be larger and more abundant. Depending on hosting provider this could be mean lighting your wallet on fire every month till you either get enough donations to make up for it, or you give up and shut it down.

This problem will only get worse as Lemmy increases in popularity from "extremely niche, extremely low volume"/trivial volume (~50-100k users) to anything other than that (1mill - 100mill users or further). And gets more difficult since economies of scale may be difficult to apply here due to the hosting model of Lemmy, meaning cost/user is likely to stay quite high when normally it would be drastically reduced the more users you have.

I'm gonna guess individual instances are going to be forced to break down into instances that host only a couple communities each as time goes on. This would be the pragmatic choice since it's very likely that individual communities can grow large enough to tank Lemmy instance performance for all others on that instance. Although that presents non-trivial UX concerns.

Though, again, many smaller scale instances means infrastructure costs may stay prohibitively high as a result of over provisioning or a lack of value from aggressive caching, read replicas...etc 🤔

Edit: I wonder if an instance can host individual communities on their own hardware. Or if there is some abstraction that lets users browse potentially hundreds/thousands of instances easily as if they where all communities?

I agree that having many smaller instances which serve more distinct communities is by far the most pragmatic choice. The idea of communities distinct from instances is nice on paper, but it gives instance managers the impression a single instance can serve a wide-range of interests without incurring proportional overhead on the resources.

Lemmy is the closest thing we have to the evolution of reddit. So far it's just a matter of handling the backend which was nearly always done by a well-resourced organization instead of individual volunteers. I think instances will naturally become more abundant, and specific to their purposes, and users will be able to distribute their accounts accordingly.

Some of the apps like Memmy throw an error and then leave you back at the comment screen. Most people probably try again because the comment and submit button is right there.

What they don’t realize is that despite the error, most times the server has accepted the comment.

Don’t get me wrong, I love Memmy (it’s been my primary driver) but this one error combined with poor performance of the lemmy.world instance (also not their fault, growing pains are a good problem to have! Hopefully not for too long….) is probably a significant contributor to this issue since many people probably don’t realize what the error means since it only says “syntax error: JSON Parse Error - unexpected token ‘<‘“ which doesn’t mean anything if you don’t speak nerd.

(For anyone who might wonder: if you are expecting json data which looks {“like”:”this”,”with”:”curly braces”} and instead you get a 500 Server Error web page which is an <html><body>Because the server is sending an error explain for a human to read displayed in browser</body></html> then your program gets confused why there is a < at the start instead of a { and now maybe the error text seems a bit less cryptic)

2 more...

You should also know you can join smaller instances to help alleviate this problem. You'll still see most of the same content, especially if the instance has active users. Don't be too shy to sign up on some random instance, worse case scenario you just don't get approved.

I joined my instance after being on Lemmy.ml about a month ago for a day, and there was so much lag because it was the largest instance at the time. I then switched to my current instance when it only had ~50 users on it and it made the world of a difference. I went from seeing the site crash every 5 seconds and posts taking 30 seconds to submit, to having a stable connection to the Fediverse.

Overall, I feel like everyone should try to join smaller instances to distribute the load so that you don’t have a bad experience, and the instances don’t get overwhelmed. It’s a win-win for everyone.

Just to add to this, at least in wefwef, I sometimes get an error when I tap Post, saying that it failed. I am then left on the page, and can hit Post again. But it didn’t fail the first time, the post was made.

So this is not just users being impatient. There is a bug.

Might be due to either the websocket removal, or the sluggishness that does it.

The post processes, but the app doesn't get a response confirming that the post has been made, so it sits there until the app times out.

It's just Lemmy admins trying to give us the true Reddit experience

You know, we don't have to copy everything from Reddit. Although it is pretty funny that we have exactly the same bug lol

Just get off .World and onto another instance and it’s smooth sailing with mobile apps working great too.

programming.dev is getting to be pretty damn slow too...

Comments post in 5-30 seconds, and up votes can take 30+ seconds to post. Searches are pointless, and loading comments can be a repetitive painful process of reloading till it works (504 gateway timeout)

Yes! The Lemmy devs should make it so that you can't hit the submit button 10 times in a row. People hit submit and nothing happens so they hit it again and again and again. Now there's a bunch of identical posts.

I remember the old days where sites would have a message saying "only hit submit once". That's gone now since sites prevent users from hitting submit more than once. I don't think Lemmy is doing that though!

You should be able to hit the submit button as many times as you want, but it should have a single transaction ID so the server can ignore duplicate submissions.

Yep, it’s called an idempotent key. The server gets a request with a specific key (usually a random guid), stores it and ignores any further requests with the same key. It would be a great addition to Lemmy.

It's problematic because often you'll get an error that says it failed to post the comment. In which case it's fair to try again, but it actually posted anyways.

I can confirm this is true in Jerboa; learned the other day the hard way.

I said I was sorry... Gosh

Resubmitting is the reasonable response to an error that said it failed. Lemmy should add some sort of duplicate message prevention when they have the time to improve the ux.

...And I learned that I need to copy the whole comment I type before submit jic my comment didn't upload, at least I have my comment restored.

Admin needs to sticky something to this effect.

What I do (web browser) is simply refresh the community to see if the post has posted yet. If it hasn't, I try again. Around a third of the time you get spinny wheel though, it actually did submit, and just forgot to let you know.

Also note that if a large amount of time has passed while you're writing a response, you'll sort of time out, and the first attempt to post won't work, but because it's refreshing your session. The second attempt will post

Even for short ones, it seems to happen always for me if I reply to one person, then try to write a top-level reply after that.

I copy any of my comments that took a while to type (longer, detailed, or sometimes just adhd) before hitting submit. I've been burned too many times from all different areas of technology. If something goes wrong, just try again and paste whatever I typed out

or you can check your personal history

Yes, but they're not going to know to do that. People will post, see error, retry, give up and move on.

I've been finding uploading images to be very confusing as the 'upload file' and 'From url' buttons don't seem to do anything

Does it show up repeatedly on your profile? I used to use that as a way to track double posting on reddit

I was wondering the same thing because I've definitely pushed submit multiple times but in my profile it only shows the comments once.

The problem is a UI thing too. In wefwef for example half the time you go to post something and it says ‘error posting’, your comment actually did post. But sometimes it doesn’t.

I typically go until I see success and then delete any duplicates I left on accident.

Only sometimes. Other times it won't post your comment at all. I still check to make sure my comments don't post more than once but sometimes the lag is so bad it's impossible to do even that.

I've had that happen a few time now too. I did it earlier today, the because of lag couldn't delete the second comment. Thanks for the tip!

I made a post and got "network error", but it turns out it went through anyway. Took three tries to not get the error, so I ended up making three posts. Had to delete the two extras.

And then the delete doesn't federate fast enough :/

Speaking of not fast... I just got 8 comment replies in my inbox that were made up to 3 days ago.

Were they from lemmy.workd? I know they were backed up for a few days but maybe the recent upgrades fixed it? I have posts that I know are missing lemmy.world comments from a week ago that met the same fate..

I don't think it is related to the amount of times one clicked submit. Duplicated posts appear anyway.

Hello there, and welcome to our community! I hope you like it in here.

Could you please include some body text as to why should people know this, and how would that help them? It’s our second rule. Thank you :)