We have moved to a new Sailfish OS Forum. Please start new discussions there.
0

Contacts not visible in contacts app after import via CLI

asked 2014-12-24 22:00:33 +0300

tdb gravatar image

I decided to treat myself to a Jolla for Christmas now that TOHKBD is coming. Obviously I wanted to import all of my contacts from my old N900. I searched the web and found instructions for doing it in various ways. I decided to try the vCard method first. Export from N900 with osso-addressbook-backup went well enough, but after transferring the file to Jolla the problems began. The device just plain refused to see the file. I tried putting it in Documents, Downloads, or the root storage directory (i.e. the nemo user's home directory). I tried moving it away from the device and back. I made sure the file extension is .vcf, and checked that Windows can read the contacts from it. I copied it to a Linux computer and used my tools there to make sure all lines ended in \r\n (after import most lines did but the terminating line of each contact had \n only). But every time I select "Import contacts from file" on Jolla, it says there are no vCard files.

At this point I also tried importing over Bloetooth. Pairing the devices seemed to work, but when it should have shown a list of contacts to import, instead the contacts app activated and showed an empty contact list. So no luck there either.

After a bit more searching I stumbled upon the vcardconverter program. Documentation was parse, but given the optional --export switch, I guessed that not giving that switch would cause it to import. I was correct. Only, the damn contacts still do not show up on the phone's screen! If I do contacts-tool list, I get a list of the 150 contacts I imported. Inspecting the file .local/share/system/privileged/Contacts/qtcontacts-sqlite/contacts.db with sqlite3 turns up nothing though, and vcardconverter --export produces an empty file. Grepping for various contact names consistently turns up .cache/tracker/meta.db and nothing else.

So:

  1. Where did the contacts go when I used vcardconverter?
  2. Why are there even two separate places for contacts?
  3. How do I get the damn things visible in the UI so I can actually start using my Jolla?
edit retag flag offensive close delete

Comments

This morning the .vcf file appeared in the import list, but importing the contacts still didn't work. However, I was able to transfer the contacts over Bluetooth by sending them from the N900. My immediate problem is thus solved, but I'd still like to know if I did something wrong with the vCard file.

tdb ( 2014-12-25 11:37:08 +0300 )edit

1 Answer

Sort by » oldest newest most voted
4

answered 2014-12-28 00:20:57 +0300

MattVogt gravatar image

The Jolla device has two contacts stores - one for privileged applications and another which contains data that is permitted to be exported from the device to other consumers, such as android applications. If your process has access to the privileged store, it will use that one, otherwise it will use the nonprivileged store (found at ~/.local/share/system/Contacts ).

If you run vcardconverter from a privileged shell (where devel-su -p has been used to acquire privileges) then it will be a privileged process accessing the primary contacts store. Otherwise, you will have imported the data into the nonprivileged store, from where Jolla apps won't see it.

edit flag offensive delete publish link more
Login/Signup to Answer

Question tools

Follow
1 follower

Stats

Asked: 2014-12-24 22:00:33 +0300

Seen: 343 times

Last updated: Dec 28 '14