This forum has been archived. All content is frozen. Please use KDE Discuss instead.

[FIXED? - YES!] KMail - New contacts problem

Tags: None
(comma "," separated)
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS
KDE 4.4.2
OS: Kubuntu Karmic Koala 9.10 (32-bit)
Kontact: 4.4.2
Kmail: 1.13.2
Akonadiconcole: 4.4.2
Akonadi-server: 1.3.1

I added a new contact from a received email: right-click on the displayed email address in the From: field and select Open in Address Book and add what ever additional information I want. Click Ok.

When I create a new email message, the newly added contact doesn't show when I start typing the contact name. All my other contacts do show when I start to type their names in the To: field.

This appears to be an database indexing 'delay' issue. If I wait for a while, and then create a new email message, when I type in the newly added contact name in the To: field I am shown Recent Addresses and the contacts entry for this addressee. I'm still not able to have Kontact bring up the new contact by its Nickname.

This isn't the 'normal' behavior is it?

Last edited by Snowhog on Fri Apr 30, 2010 7:04 pm, edited 3 times in total.


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
annew
Manager
Posts
1155
Karma
11
OS
Someone else remarked on the delay. I don't know what causes it, but I suspect that it is not immediately copied into the cache, which is what gives faster access to existing entries.

As for being able to find by nickname, no, it's not normal. I can start to type a nick and get the correct entry suggested. Some questions to help track this down:

Do you have more than one addressbook defined? Have you defined your default addressbook? Are you sure the entries you are trying to find are in the default addressbook?

http://userbase.kde.org/KAddressBook#Enabling_Resources tells you how to check your resources are enabled, and how to define the default.

Anne


annew, proud to be a member of KDE forums since 2008-Oct and a KDE user since 2002.
Join us on http://userbase.kde.org
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS

Re: KMail - New contacts problem

Fri Apr 02, 2010 4:08 am
Thank you. Your link allowed me to identify what I think was the problem. The Akonadi contacts resource was pointing to ~/.local/share/apps/contacts while the entry in KDE Resources was pointing to another user location. Both had my address contacts; one with individual .vcf files and the other with a single .vcf file. Long story short, I uninstalled kontact, kmail, and kaddressbook and then reinstalled them. Ensured that both Akonadi and KDE Resources were pointing to the same location.

Now my 'added' contacts appear and are selectable with their assigned nicknames. All appears to be good.


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
annew
Manager
Posts
1155
Karma
11
OS
Glad you got it sorted. YOu didn't need to re-install, but since you've done it, that's academic. You say they both point to the same place - did you point them to/.local/share/apps/contacts? That's the one that KAddressBook (and thereore KMail) will see as Personal Contacts.


annew, proud to be a member of KDE forums since 2008-Oct and a KDE user since 2002.
Join us on http://userbase.kde.org
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS
No. Both are pointing to ~/.kde/share/apps/kabc/std.vcf

~/.local/share/apps/contacts "did" exist until, after uninstalling kontact, kmail, and kaddressbook, I removed it. After reinstalling these three, that directory was not recreated.


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
annew
Manager
Posts
1155
Karma
11
OS
Hmm - we need to get the akonadi-controlled addressbook working. What do you get when you type 'akonadictl status' into a user konsole? If it's stopped, try exiting KMail and running 'akonadictl start' in konsole before you re-start Kontact. Hopefully the addressbook will be recreated, and you can then point your default resource to that. If it doesn't get re-created I'll ask the developers about this.


annew, proud to be a member of KDE forums since 2008-Oct and a KDE user since 2002.
Join us on http://userbase.kde.org
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS
I have Kontact up and running. Opening a console and typing:
akonadictl status

shows:
paul@myotherbrain:~$ akonadictl status
Akonadi Control: running
Akonadi Server: running
Akonadi Server Search Support: available (backend: Virtuoso)

And the contents of ~/.local/share/ are:
paul@myotherbrain:~/.local/share$ dir
total 32
drwxr-xr-x 5 paul paul 4096 2010-04-03 07:35 akonadi
drwx------ 2 paul paul 4096 2010-03-31 13:10 applications
drwxr-xr-x 5 paul paul 4096 2010-02-10 22:59 local-mail
drwx------ 4 paul paul 4096 2010-01-02 22:02 mime
drwx------ 4 paul paul 4096 2010-03-27 22:43 Trash
-rw-r--r-- 1 paul paul 884 2010-01-23 15:08 user-places.xbel
-rw-r--r-- 1 paul paul 884 2010-01-23 15:08 user-places.xbel.bak
-rw-r--r-- 1 paul paul 0 2010-01-23 15:08 user-places.xbel.tbcache
drwx------ 3 paul paul 4096 2010-01-25 18:14 vlc

Akonadi is running. Kontact works fine. My contacts are shown, accessible, and located when creating new email messages when typing into the To:, CC:, or BCC: fields, either by contact name or nickname.

I still have some issues with Akonadi when it first starts (when launching Kontact), in that, the Akonadi Server Self Test will *sometimes* report a failure on no resource agents found. I have a separate post on that whole issue here. When it happens, I just shutdown Kontact and restart it. Then Akonadi is 'happy' and my contacts work as expected.

So, if there is a configuration *problem* with my current setup, it at least works for me. That said, I would of course, like to have it all setup *and working* as it was designed to be.

I'm willing to help troubleshoot this. Just let me know what additional information you need.


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
annew
Manager
Posts
1155
Karma
11
OS
Hmm - no Contacts directory. Presumably that's what you deleted? Have you tried creating the directory, stopping Akonadi then re-starting it? I'm clutching at straws, as a holiday weekend isn't the best time for catching the developers to ask them.

For the moment you are able to work, as you say. And I'm certainly not worried that this will cause you any immediate problem. The problem is that it's the Personal Contacts, stored in ~/.local/share/contacts/ that is the main Akonadi resource, and I'm worried that when KMail moves to Akonadi you may run into trouble if we don't get this sorted first (not that there's a frantic rush, of course). http://userbase.kde.org/Akonadi_and_AddressBook will explain why I'm uncomfortable with your present situation continuing for too long :-)

I will definitely try to find out how to get the migration run again, but it may take me a few days, because of the holiday.


annew, proud to be a member of KDE forums since 2008-Oct and a KDE user since 2002.
Join us on http://userbase.kde.org
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS
Okay. KDE Resources didn't have an akonadi-resource, so I added it. Then I edited that and added Address Book and Personal Contacts.

Address Book points to ~/.kde/share/apps/kabc/std.vcf
The actual std.vcf file is a zero byte file - a template? - and (currently) three *numbered* std.vcf files (std.vcf_4, std.vcf_5, and std.vcf_6) which contain my contacts. Given that each of these files has a different creation date, I'm deducing that when a modification to the file is made on other than the date it was last modified, a copy of the previous is made. Is this correct?

Personal Contacts points to ~/.local/share/contacts/
This directory was empty when Kontact was launched, as all my addresses were in the Address Book directory above.

Upon starting Kontact and clicking on Contacts, the Address Book column showed two entries: Address Book and Personal Contacts. Clicking on Address Book displayed my entries in the Name column, which was expected. Clicking on Personal Contacts showed nothing in the Name column. That was also expected.

From within Kontact > Contacts, I copied the contents of Address Book and pasted them into Personal Contacts. Checked ~/.local/share/contacts and it now contains individual .vcf files, one for each contact. I then deleted the entries in Address Book. Now, when I click on Contacts > Address Book, nothing shows in the Name column (expected) and clicking on Contacts > Personal Contacts, my entries show in the Name column (expected).

Clicking New Message, my *recipients* are locatable when typing in To:, CC:, and BCC: either by name or nickname.

So, is this now the *correct* setup and behavior?

What is the intent/design of having 'personal contacts' being separate from ones 'address book'?


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS
Examining your Resources

KRunner offers you Akonadi Resource Configuration, or you can access this through the Akonadi tray icon > Configure. You may find several resources set up. You may find one labelled

Address Book - No KDE address book plugin configured yet.
That's the old compatibility bridge (possibly created by the migrator tool). You should remove this one!

std.vcf - Ready

This is the 'VCard File Resource' which points to $HOME/.kde/share/apps/kabc/std.vcf per default. It is not recommended that you use that one, as it doesn't share the benefit of Akonadi.

Personal Contacts - Offline

That's the preferred resource for your local contacts which points to
$HOME/.local/share/contacts


Does this mean I should not add Address Book in Akonadi Resources Configuration, and only have Personal Contacts and Local Folders?


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
annew
Manager
Posts
1155
Karma
11
OS
Hehe - an unconventional solution, but it does seem to have worked! I wouldn't have deleted the entries in your old addressbook, though. I don't know its future, but my personal feeling is that I want to keep std.vcf around, 'just in case' :-) I'd be inclined to copy /home/anne/.kde/share/apps/kabc/std.vcf_1 into std.vcf and just leave it around.

I have the std.vcf AddressBook as one of my resources - I'm not using it, and it does no harm. I could probably remove it as a resource, but there's no need to. If you leave it you may have to follow the UserBase instructions to set Personal Contacts as your default. You should add new entries to this one, and any backups you do should include that directory.

It sounds as though you've got this more or less under your belt now, and are just tidying thing up.


annew, proud to be a member of KDE forums since 2008-Oct and a KDE user since 2002.
Join us on http://userbase.kde.org
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS
annew wrote:I wouldn't have deleted the entries in your old addressbook, though. I don't know its future, but my personal feeling is that I want to keep std.vcf around, 'just in case' :-) I'd be inclined to copy /home/anne/.kde/share/apps/kabc/std.vcf_1 into std.vcf and just leave it around.

Done.

I have the std.vcf AddressBook as one of my resources - I'm not using it, and it does no harm. I could probably remove it as a resource, but there's no need to. If you leave it you may have to follow the UserBase instructions to set Personal Contacts as your default. You should add new entries to this one, and any backups you do should include that directory.


Esthetically, I don't like that. Having both visible in Contacts under the Address Book column just bugs me. So, I removed the std.vcf as a resource.

This means of course, that new contacts are added into the Personal Contacts resource as individual .vcf files in ~/.local/share/contacts/

This raises an observation and subsequent question. First, all email address are in Personal Contacts, and that resource can't be renamed, at least, I haven't found a way to do so. Most address books allow for tagging of entries as Business, Family, etc., and in fact, KMail pre-akonadi allowed this. This allowed one to filter the address book contents.

Is there any way to do this now? Akonadi only allows for one Personal Contact resource (as far as I can tell).


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
annew
Manager
Posts
1155
Karma
11
OS
Within Personal Contacts you can create folders, then either copy or move addresses there. Like distribution lists, I don't think this has reached its full potential, but I find it quite convenient to have all my kde addresses in one folder, and all the addresses for another club I belong to in a different folder. They are stored as sub-folders of Personal Contacts, so they get backed up along with the main addressbook. I believe tagging is another thing that will come back in one form or another, in 4.5


annew, proud to be a member of KDE forums since 2008-Oct and a KDE user since 2002.
Join us on http://userbase.kde.org
User avatar
Snowhog
Registered Member
Posts
198
Karma
1
OS
Thank you. Okay, did that. I created the sub-folders I wanted from the console.

CD .local/share/contacts
mkdir Family
mkdir Friends
mkdir Work
mkdir Other

Restarted Kontact and clicked on Contacts. These new folders were not listed as folders in Personal Contacts. Hmm. So, I right-clicked on Personal Contacts > Add Personal Address Folder... and created these four entries. Then I drag-dropped my contacts into the correct folders, choosing 'Move Here'. When finished, there were no more contacts shown when clicking on Personal Contacts (expected), and when clicking on each of the new folders, the contacts I moved there displayed in the Name column (expected). However, when I shutdown Kontact and then relaunched it, clicking on Contacts shows that in Personal Contacts, all the entries I moved are listed in the Name Column. Each of the folders, when clicked, displays just the contacts I moved into them.

A listing of ~/.local/share/contacts shows:
paul@myotherbrain:~/.local/share/contacts$ ls -la
total 28
drwxr-xr-x 6 paul paul 4096 2010-04-04 11:08 .
drwx------ 10 paul paul 4096 2010-04-03 13:02 ..
drwxr-xr-x 2 paul paul 4096 2010-04-04 11:05 Family
drwxr-xr-x 2 paul paul 4096 2010-04-04 11:05 Friends
drwxr-xr-x 2 paul paul 4096 2010-04-04 11:06 Other
-rw-r--r-- 1 paul paul 122 2010-04-03 13:07 WARNING_README.txt
drwxr-xr-x 2 paul paul 4096 2010-04-04 11:03 Work
paul@myotherbrain:~/.local/share/contacts$


So why is akonadi (I'm assuming it's akonadi) showing entries in Personal Contacts that no longer exist in that location?

Image
Image


Administrator
Kubuntu Forums . Net - https://kubuntuforums.net
User avatar
annew
Manager
Posts
1155
Karma
11
OS
We're into the field of guesswork here, but I think that, in terms of the database, they are not in separate addressbooks. I *think* that creating these subfolders is akin to tagging entries from the Personal Contacts. This is purely my assessment, based on my experience. I haven't seen any comment on that subject from the developers, so it could be something quite different.


annew, proud to be a member of KDE forums since 2008-Oct and a KDE user since 2002.
Join us on http://userbase.kde.org


Bookmarks



Who is online

Registered users: Bing [Bot], blue_bullet, Google [Bot], rockscient, Yahoo [Bot]