GNOME Bugzilla – Bug 617715
if an account is recreated, reuse the existing chat logs
Last modified: 2018-05-22 14:12:15 UTC
Ok so here's what happened: my gnome keyring crashed (I tried deleting some keys in seahorse, and the thing just locked up) and corrupt itself. Well ok, no biggie. rm ~/.gnome2/keyrings and logout and relogin into gnome right?
The problem is that Empathy really didn't seem to handle it well. I had the following accounts:
- an IRC account with password
- a salut account
- a jabber account
- a butterfly account
- a couple of other inactive or test accounts
When I started empathy, only the salut account and the IRC account were left, with the IRC account having "lost" its password.
The logs in ~/.local/share/Empathy/logs are still all there, so I tried creating my jabber account anew. It worked, *but*... it doesn't "match" the existing log files to it:
Thus, if I right-click anyone in the contact list, the "Show previous conversations" option is greyed out, and if I go into the log viewer (F3), by default the IRC account is selected instead of the jabber account, and when I go to select the jabber account, I see it's there "twice". One of the two instances (the new one) has no log files!
Attached is the generic debug log from empathy, which looks a bit suspicious.
I'm not used to saying this, but please help! I can't use empathy until I solve+fix this mystery, I don't want to lose data :(
Created attachment 160315 [details]
Created attachment 160316 [details]
screenshot (accounts dialog and chat history)
This bug is basically the same issue as bug #586562. Once we'll support accounts without saved password, Empathy would be able to ask for the password instead of "loosing" the account (actually the account is lost
by mission-control). Closing this bug as a dup as that's really the same issue.
Don't worry, I'm sure we can restore your old logs. Logs are stored in ~/.local/share/Empathy/logs/$ACCOUNT
If you copy the files from the old account to the new one that should work.
*** This bug has been marked as a duplicate of bug 586562 ***
Ok rather than "don't silently blow up my accounts when they don't have a password", the question becomes a different one: why does empathy allow for the same account (same jabber ID for example) to create two different folders instead of reusing the existing one? Now I have the following log folders:
gabble_jabber_jeff_40im_2eecchi_2eca0 # The old one containing the logs
gabble_jabber_jeff_40im_2eecchi_2eca1 # The new account
Why does the 2nd one even exist instead of reusing the first one?
Another thing that is very puzzling is that, after moving the logs from the 0 folder to the 1 folder, deleting the 0 folder (gabble_jabber_jeff_40im_2eecchi_2eca0), there are *still* two "accounts" showing up in the chat log viewer... as if there still was a ghost account laying around.
Where does it actually store the list of accounts?
That's because from a Telepathy pov those accounts are different. Empathy could MAYBE have some heuristic to avoid re-creating account but I'm afraid to corrupt existing account in case of bug.
Accounts are stored in ~/.mission-control/accounts/accounts.cfg
Removing your account from there should fix your ghost issue.
Btw, I added few days ago a new entry into the FAQ which should answer all your storage questions :)
Created attachment 160385 [details]
sample account file
Thanks for the pointers, I have been able to (carefully) cleanup the accounts.cfg file.
I'm attaching it here so you can see what happened: gabble/jabber/jeff_40im_2eecchi_2eca0 got removed from the keyring but empathy didn't delete it completely (it was just ... not shown in the account manager, I guess). Then I created account the account, so it added gabble/jabber/jeff_40im_2eecchi_2eca1.
However, if you compare the two, they are 100% identical except their internal name.
I guess the bug kinda becomes "the account was not really deleted, it was hidden".
-- GitLab Migration Automatic Message --
This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.
You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/empathy/issues/232.