Adium

Ticket #1880 (closed defect: fixed)

Opened 3 years ago

Last modified 4 months ago

Group chats don't reconnect after being disconnected

Reported by: ttimo@idsoftware.com Assigned to: nobody
Priority: normal Milestone: Adium X 1.2.1
Component: Jabber/XMPP Version: 0.85
Severity: normal Keywords: WasOn1.5
Cc: Patch: Needs Dev Review
Pending: 0

Description

if I open a group chat to a jabber server, and let the machine go to sleep, adium will reconnect when coming back from sleep. but the group chat will be unchanged. I can type in and see my own echo, but I'm disconnected.

Attachments

autorejoin.diff (7.7 kB) - added by erik006 on 11/23/2007 11:51:39 AM.
should automatically reconnect the group chats - enumerates through chats, creates a bookmark when a group chat is found, creates new purple chat

Change History

10/14/2005 09:54:11 AM changed by tick

  • version set to 0.85.
  • milestone set to Adium X 1.5.

So to clarify, you want to autojoin open group chats if adium is running with them open when the computer goes to sleep?

10/14/2005 09:56:47 AM changed by ttimo@idsoftware.com

yes. it does reconnect to jabber and other IMs, so it should also reconnect the chats. The current behaviour is very misleading atm as you think you are still online ( you can type and see your messages in the group chat window ), but in reality you are offline.

01/18/2006 12:48:06 AM changed by sarah

Having this same problem with AIM-based chat rooms. If the machine goes to sleep or your network connection drops while you're away from it, there is no notification that you have left the chat room. No message is displayed in the console and all chat participants that were in there when it lost connectivity are still listed, so you can sit there and talk to yourself without realizing it. Even a chat error/"you have left chat" notification line in the console on logout/disconnect would be really helpful. Thanks!

04/11/2006 09:31:57 PM changed by avirr

I'm constantly having the same trouble in AIM, it's really really really annoying. One of the few significant flaws in Adium. Please fix ASAP.

02/06/2007 11:09:15 PM changed by evands

  • summary changed from jabber group chat doesn't reconnect to Group chats don't reconnect after being disconnected.
  • field_haspatch changed.

08/22/2007 05:43:39 AM changed by irabinovitch

#5404 seems to cover this same issue, but specifically mentions jabber. Per my comments in #5404, it would be helpful to at least have some sort of error message in the chat window indicating you are disconnected and not actually in the room.

Without such a message there is a no way for a user to tell if they are actually in the room or not. In many cases I will not notice I have been disconnected, and time lengthy messages which appear to be sent to the room. Later I find out I've actually been out of the room and that my messages were lost into the ether.

08/28/2007 12:13:29 AM changed by larse

+1 for fixing this. It is really annoying.

Also, as I reported in #7388 (closed, but it is *not* a duplicate of this ticket), it's not even possible to manually rejoin jabber chats with the same handle after a disconnect.

09/17/2007 10:57:40 AM changed by tick

  • keywords set to WasOn1.5.
  • milestone changed from Adium X 1.5 to Good idea for "later".

As the group chat SoC 2007 project completed successfully, we no longer require a group chat milestone. As such, I'm going to move all of these over to Good Idea for "later". Process these normally, reassign as needed to the new 1.x milestones created last night.

10/30/2007 04:15:02 AM changed by evands

  • patch_status set to None.
  • pending changed.
  • milestone changed from Good idea for "later" to Adium X 1.2.1.

This is pretty trivial to implement given the changes made to support bookmarks in 1.2.

11/20/2007 09:25:40 AM changed by erik006

  • patch_status changed from None to Needs Dev Review.

11/20/2007 09:27:37 AM changed by erik006

This is a bit ugly, the interface actually get closed and re-opened with this patch. However, I don't believe there is a way to do this that looks better right now. Possibly we can replace the chat in a chat container, but that creates the possibility of having a container with no associated chat -> not good.

11/20/2007 10:33:01 AM changed by evands

  • patch_status changed from Needs Dev Review to Needs Changes by Author.

Don't be afraid to dig a bit, implementing what you need at any level, to be able to solve things Right. This is a good start; some suggestions:

  • Check the chat's account. Only take action if the chat is on the account which connected.
  • Check whether the chat is open. Only take action if the chat is open.
  • Going through AIListBookmark feels awkward... though not as awkward as closing the chat and reopening it. Here's my thought on a more Complete approach to the problem:
    • You can get the chatCreationDictionary directly from the chat.
    • Then you should write a new AIAccount method rejoinChat:...
    • CBPurpleAccount overrides the method and performs action through SLPurpleCocoaAdapter much like openChat: does, except that it clears the chat identifier before telling it to open.
    • Clearing the chat identifier makes convLookupFromChat() in SLPurpleCocoaAdapter recreate the components hash table and resend the info to serv_join_chat().

(Note: It would sound more straightforward to just clear the identifier in AIChatController before passing it to the account, but it's an account implementation detail that the identifier is used the way it is for Purple accounts. Another AIAccount subclass might expect the identifier to be persistent and take action to rejoin another way.

Hope that helps!

11/23/2007 11:51:39 AM changed by erik006

  • attachment autorejoin.diff added.

should automatically reconnect the group chats - enumerates through chats, creates a bookmark when a group chat is found, creates new purple chat

11/23/2007 11:52:14 AM changed by erik006

  • patch_status changed from Needs Changes by Author to Needs Dev Review.

11/23/2007 03:10:36 PM changed by erik006

I discovered a problem: when using a global disconnect (using the emd), we don't receive all connection notifications. Although I'm not quite sure why this is.

01/03/2008 05:40:39 PM changed by googelybear

+1 for fixing this. It is really annoying.

01/06/2008 05:48:33 AM changed by fantux

This actually got worse with Adium 1.2. Now it tells you in the chat window that you have been disconnected and then reconnected, however you still get the same behaviour as in the initial posting.

01/06/2008 09:56:57 PM changed by evands

(In [22158]) Added a note about the ACCOUNT_CONNECTED / ACCOUNT_DISCONNECTED events (and their associated notifications): they are intended to indicate that a particular account connected or disconnected, as they will be aggregated for multiple account connectivity changes in a short period of time. Refs #1880 where erik006 pointed out that this was nonintuitive.

01/06/2008 10:21:23 PM changed by evands

  • status changed from new to closed.
  • resolution set to fixed.

(In [22161]) Based on a patch from Erik Beerepoot, group chats now reconnect after their account has reconnected. "You have disconnected" displays when the account goes offline, but "You have connected" does not display as soon as it comes online; rather, we'll let the joined-chat message indicate this. Fixes #1880

01/06/2008 10:22:17 PM changed by evands

(In [22162]) Merged [22161]: Based on a patch from Erik Beerepoot, group chats now reconnect after their account has reconnected. "You have disconnected" displays when the account goes offline, but "You have connected" does not display as soon as it comes online; rather, we'll let the joined-chat message indicate this. Fixes #1880

01/14/2008 06:01:48 PM changed by evands

  • milestone changed from Adium X 1.2.1 to Adium X 1.2.2.

01/15/2008 09:54:52 PM changed by evands

  • milestone changed from Adium X 1.2.2 to Adium X 1.2.1.

01/16/2008 09:24:35 AM changed by fantux

In 1.2.1b1 this again worsened somewhat. T'is what happens:

  • OSX10.4, MacBook
  • Adium 1.2.1 beta 1
  • go online, join a Jabber-MUC
  • Close the lid, let the computer go to sleep
  • Open the lid, wake the computer
  • Let Adium reconnect

The chat window displays messages from other users all right, but my own messages are not relayed to the MUC. When attempting to manually rejoin the MUC (close chat window, then either 'go to chat' or double-click on the bookmark), nothing happens (no window opens). Further wildly clicking around shows that regular chat does work, while this particular MUC does not (no second MUC around for testing that, unfortunately). Changing the Handle in the 'go to chat'-window does not do any good either.

The only solution so far is to quit and restart Adium.

01/16/2008 11:22:44 AM changed by evands

  • status changed from closed to reopened.
  • resolution deleted.

Can't believe I didn't test that - I just noted that incoming messages worked.

01/16/2008 08:26:34 PM changed by evands

  • status changed from reopened to closed.
  • resolution set to fixed.

(In [22373]) Fixed rejoining of chats to properly reassociate AIChat to PurpleConversation and visa versa. Fixes #1880

01/16/2008 08:27:01 PM changed by evands

(In [22374]) Merged [22373]: Fixed rejoining of chats to properly reassociate AIChat to PurpleConversation and visa versa. Fixes #1880