So, there was I, spamming my useless messages and I got this "unknown error" with the usual "retry" message that I use to get on some connection failure (which I think yields a different error message).

And as soon as I clicked "retry" the whole message disappeared even from the up arrow.

I have no idea how to replicate it!

But hopefully the following image and links should be enough proof it happened, and good for debugging on the logs.

Missing in the image, but that ghosty message does appear on the transcript!

  • Is this before or after a refresh of chat?
    – TheLQ
    Sep 29, 2010 at 23:12
  • @TheLQ what you mean? I never refresh the chat.
    – cregox
    Sep 30, 2010 at 12:21

1 Answer 1


TL;DR: Fixed now.

If you're interested, here's what happened.

When you post a message, this causes two things to happen:

  1. The message is put into the messages table in the database, and
  2. the message posting event is pushed into the event queue.

When you look at the transcript, the messages you see there come from the messages table. The same is true for the messages you see when you first open a chat page.

But while you watch new messages come in, these are pulled from the event queue.

So if step 1) is completed successfully, but step 2) fails for whatever reason, the message is there (that's why you see it in the transcript, and that's why you would have seen it had you refreshed the page), but the clients (including yours) never get notified, because there is no event.

So in your case, step 1 succeeded, but step 2 failed (likely because of a database timeout). So your client was notified of the fail and hence offered you the "retry/cancel" option.

So you clicked "retry", and your client re-sent the message. But the server noticed that this is the exact same message you sent a few seconds earlier (there's an automatic dupe detection, to prevent accidental double-posts -- and, in fact, it would have been a double post, as you see in the transcript).

So the server responded "yeah yeah, I know about this message already", and the client said "oh, okay" and removed it.

This is now fixed by making sure that 1) and 2) happen in one transaction, so either both succeed or both fail.

On a side note, if you really never refresh the chat: You should do that once in a while, or you miss out on all the awesomeness that constantly gets added :)

  • I still don't quite get that "refresh the chat". You mean reload the page for "upgrading" the system? If so, I'll pay more attention to it. - And thanks for the detailed explanation. It's always interesting to know how great and properly complex systems work
    – cregox
    Sep 30, 2010 at 15:18
  • Do the server and the client really talk like that to each other?
    – juan
    Sep 30, 2010 at 15:21
  • @Cawas sure -- after all, the client-side part is just a webpage with a whole lot of JavaScript in it. So if we fix a bug in the client or add new features to it, you won't see it until you get the new JS -- i.e. hit F5.
    – balpha Staff
    Sep 30, 2010 at 15:25
  • 1
    @Juan no, actually they talk in LOLspeak. I just translated it here.
    – balpha Staff
    Sep 30, 2010 at 15:26
  • Is that dupe detection why I can't say "G'nite, everyone ♪" into two rooms one after the other?
    – Grace Note StaffMod
    Sep 30, 2010 at 16:08
  • @balpha what about displaying an ajax warning that we should "reload or click [here]" to be able to enjoy the new features of the chat interface?
    – cregox
    Sep 30, 2010 at 16:24
  • @grace I doubt that has anything to do with duping detection.
    – cregox
    Sep 30, 2010 at 16:24
  • @Cawas we notify people if we fix a critical bug in the client (this has happened once). But if we notified you everytime we push an update, you'd get annoyed pretty quickly. Also, some people even turn their computers off once in a while :)
    – balpha Staff
    Sep 30, 2010 at 16:35
  • @balpha depends on which computer, I turn it off (my mac just go to sleep)... but then the browser restores my tabs and I'm not sure if it reloads pages. I think not. but those (of yours) are good news! :)
    – cregox
    Sep 30, 2010 at 17:31
  • 1
    balpha, have I told you recently that you ROCK? :-) Sep 30, 2010 at 21:22
  • @balpha Just some nostalgia here and extra compliments: identifying (from the little info I've gave) and fixing this sneaky bug in less than 24 hours was just awesome! :)
    – cregox
    Oct 7, 2015 at 12:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .