Facebook and the N900 address book

The N900 address book can merge multiple contacts into a single entity: if you have a friend that has a phone number, an email address, a Jabber user name, a MSN one and so on, then you can merge all of the different entities into a single meta-contact.

Locally stored details and an IM user name in the same contact
Locally stored details and an IM user name in the same contact

The different IM contacts are tracked through their username and should be immutable[1], but yesterday Facebook changed all the IDs from something like “u123456789@chat.facebook.com” to “-123456789@chat.facebook.com”. For the address book this means that all the previous contacts were deleted from the IM roster and new contacts were added, so you get duplicate contacts. Moreover, when a contact is removed from the roster we leave the IM user name in the contact details, if you click the button you can add the contact back to one of your rosters. In the Facebook case this means that you end up with all of your meta-contacts with a useless button that cannot do nothing.

The fix for this is to remove the old IDs and merge your contacts again, simple but tedious. A better way to do it is to be patient and wait until I finish a program that will do it for you in a few click ;)

Update: I finished and release the program, see my blog post about Facebook migrator.

[1] Actually, some changes in the IDs are possible for normalisation purposes; if you add “FooBar@example.COM” it will become “foobar@example.com” in your roster. (And yes, the normalisation is buggy in PR1.1, but it will be fixed in PR1.2.)

Information and Links

Join the fray by commenting, tracking what others have to say, or linking to it from your blog.

Other Posts

Reader Comments

Cool thanks!
If only we could have metacontacts in empathy ;)

You should be happy that there are no metacontacts in empathy, so this kind of bug cannot happen! :P

Empathy has plans to include meta-contacts for their long-term goals which you can see at http://live.gnome.org/Empathy/Roadmap

I would love to have contacts act as objects/files where multiple programs (evolution, empathy, etc) can access contact files in a folder (Home > Contacts?).

[…] alegria dos seriemaníacos do N900; enquanto isso, a comunidade vai resolvendo chatices do tipo como resolver problemas com a sincronização de contatos com o Facebook, como habilitar powersaving e como avisar que a lente da câmera está […]

Thank you so much for doing this! It’s amazing that people like you help out like that. Thank you again, from all of us.

[…] […]

Noticed the same annoying thing today :( Certainly interested in your app!

Where would I find documentation on the contact database? I might able to write my own shell script.

@Daniel: it’s undocumented and not supposed to be modified directly. There are different DBs, a BSD one for the local contacts, plus a sqlite one per account. The consistency between the main DB and the IM ones is very important or things will stop working in weird ways.

Really looking forward to your app. Is there a way to get a notification when it’s available?

[…] I said in my previous blog post, some changes in the Facebook XMPP servers lead to the unmerging of the Facebook contacts that were […]

[…] I said in my previous blog post, some changes in the Facebook XMPP servers lead to the unmerging of the Facebook contacts that were […]

I saw the duplicated ids, but thought it was me playing with the facebook contacts :D

Can’t wait to see that application!

Very nice ! Now, could this application move the Extras Facebook plugin contacts to the PR1.2 official Facebook chat plugin ?

it doesnt work for me…I run it, it says all contacts were successfully merged & gives me only the option to “finish”. but NONE of them are merged! what could be the problem

If you reboot the contacts are still unmerged? If you rerun the program does it propose to merge them again?

Are you sure ?
In the first step, it just shows which contacts it thinks are mergeable, then you have to select the ones to merge, and only then it will merge them.
Did you try selecting contacts in the proposed list ?