Bug 259949 - Kmail does not use all addressbooks for autocompletion
Summary: Kmail does not use all addressbooks for autocompletion
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kmail2
Classification: Applications
Component: contact completion (show other bugs)
Version: 4.10
Platform: Ubuntu Linux
: NOR major with 987 votes (vote)
Target Milestone: ---
Assignee: David Faure
URL:
Keywords: triaged
: 251675 266609 276762 277403 297795 310082 (view as bug list)
Depends on:
Blocks: 312150 314181 315439 316035 316036 316038 317378
  Show dependency treegraph
 
Reported: 2010-12-15 13:49 UTC by m.wege
Modified: 2018-10-07 10:40 UTC (History)
94 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.10.3


Attachments
Display the unstability of this broken feature (75.82 KB, image/png)
2012-08-15 08:37 UTC, Anders Lund
Details
Attempt to fix autocompleter for 4.9.5 (918 bytes, patch)
2013-01-17 11:04 UTC, Hans-Peter Jansen
Details
Srcipts to restart the Feeder after a certain delay (438 bytes, application/x-gzip)
2013-02-15 21:19 UTC, regi.hops
Details

Note You need to log in before you can comment on or make changes to this bug.
Description m.wege 2010-12-15 13:49:20 UTC
Version:           2.0.89
OS:                Linux

I have 2 addressbooks. One old-style "KDE adressbook adressbook" (traditional) and one new akonadi-adressbook. Only the addresses of the Akonadi-addressbook show up during autocompletion in the composer. In Kmails composer-settings, where I can set up, which addressbook is used first, the addressbook itself shows up.

Reproducible: Always




OS: Linux (i686) release 2.6.37-7-generic-pae
Compiler: cc
Comment 1 m.wege 2010-12-16 12:18:31 UTC
additional information: I can select addresses from that addressbook, using the "select" menu.
Comment 2 Christian Trippe 2011-01-01 11:59:38 UTC
For me it does not even work with the "personal contacts" addressbook.
Comment 3 m.wege 2011-01-18 09:36:54 UTC
Still does not work with actuall beta. Is this a bug which does not happen on all systems? If so, how can I help to make it reproducable? Appart from speed and not working filters this bug is most anoying in Kmail2.
Comment 4 Kumaran Santhanam 2011-01-20 06:48:49 UTC
On Ubuntu 10.10 and KMail 2.0.89, I'm only able to get autocomplete to work with recent addresses.  This feature is essential to usability, so it would be good to fix it before the final KDE release.  Does anybody have a patch or workaround?
Comment 5 m.wege 2011-01-20 09:26:41 UTC
As I wrote you can select addresses from that addressbook, using the
"select" menu as a workaround (which is somehow anoying, but it works).
Comment 6 Christophe Marin 2011-05-07 19:04:56 UTC
*** Bug 251675 has been marked as a duplicate of this bug. ***
Comment 7 Philipp Schmidt 2011-05-15 14:17:02 UTC
Can confirm this in part. For me Autocompletion starts working when I typed a full Last- or Firstname, then it shows the according Items.
Comment 8 Franz Trischberger 2011-05-16 20:13:40 UTC
For me, it is the same behaviour as Philip Schmidt describes.
Take for example the name "Paulchen Panther". When i type "Pa" in the composer, nothing happens. Now, typing further, ASAP it gets "Paulchen" or "Panther", the Addressbook-completion jumps in. From this point, typing "Pa" immediately gives "Paulchen Panther" Addressbook-completion. BUT ONLY PAULCHEN PANTHER! Other Items don't get completed, until i write at least one complete word of the name.

Another thing that drives me crazy, is the completion of recent addresses: it does not match substrings starting in the middle of the Address.
Take "paulchenpanther@blackdiamond.com". When typing "paulchen", i get the address completed correctly, but "panther" does not get any completions!
This is quite annoying, as i really don't remember all the mailaddresses. people chose.
AFAIR in kmail-3.5 (probably also 4.4), the name of person also was taken into the recent addresses.
I answered a mail of Paulchen, the entry in the addressedit was "Paulchen Panther <paulchenpanther@blackdianmond.com>". Now only "paulchenpanther@blackdiamond" gets pushed in the recent used addresses.

I know, it got a little bit offtopic... Sry...
Hope the On-Topic-part was clear enough.
Comment 9 Georg Hennig 2011-06-12 10:44:38 UTC
I can confirm this strange behaviour.
Comment 10 Raimar Sandner 2011-06-12 14:10:32 UTC
For me, this seems to be fixed in kmail 2.1.0.
Comment 11 Georg Hennig 2011-06-12 19:02:54 UTC
I'm using kmail 2.1.0, and it's not fixed on my system (Gentoo, KDE 4.6.4).
Comment 12 Georg Hennig 2011-06-12 21:27:37 UTC
I have to add some information. it's becoming even stranger:
Let's again assume, there is an contact "Paulchen Panther".
First time, you start typing "Paul" it won't display any auto-completion. Now finish "Paulchen", and it will display the correct contact.
From now on, during this kmail2 session, auto-completion will work, even if you only type "Paul"! Also with new emails during this session.
However, this correct auto-completion behaviour is lost after closing kmail2.
Comment 13 Rico Rommel 2011-06-14 22:10:30 UTC
*** This bug has been confirmed by popular vote. ***
Comment 14 quazgar 2011-07-19 12:15:05 UTC
(In reply to comment #12)
Here (Kubuntu 11.04, Kontact 4.4.10, KMail 1.13.6, KAddressbook 4.4.10) the behavior is a bit different, it autocompletes after the first name is completely entered. This would be at the "n" of "Paulchen". Also auto-completion would only work until the address field is left.
Comment 15 GB 2011-07-27 08:29:57 UTC
(In reply to comment #14)
> (In reply to comment #12)
> Here (Kubuntu 11.04, Kontact 4.4.10, KMail 1.13.6, KAddressbook 4.4.10) the
> behavior is a bit different, it autocompletes after the first name is
> completely entered. This would be at the "n" of "Paulchen". Also
> auto-completion would only work until the address field is left.

Same here. Gentoo with kmail 4.6.1, kdepimlibs and kdelibs 4.6.5, akonadi 1.5.3.
Comment 16 Franz Trischberger 2011-07-30 10:02:59 UTC
@#12 & #14:
That's  exactly the behaviour I tried to describe in #8,first paragraph.
So nothing changed.

Did an update to kde-4.7.0 (including kdepim), and still the behaviour did not change.
Comment 17 H.H. 2011-08-08 12:24:47 UTC
I can confirm this bug, exactly as described in comment #c8

Please fix this soon!
Comment 18 Philipp Woelfel 2011-08-11 01:05:19 UTC
Is bug 277403 (https://bugs.kde.org/show_bug.cgi?id=277403) a dupe of this one?
Comment 19 René Serral 2011-09-01 08:51:14 UTC
I experience the same behavior with KDE-PIM 4.7.0, I only have one addressbook using akonadi-google resource
Comment 20 Christophe Marin 2011-09-14 17:55:29 UTC
*** Bug 266609 has been marked as a duplicate of this bug. ***
Comment 21 Christophe Marin 2011-09-14 17:56:20 UTC
*** Bug 277403 has been marked as a duplicate of this bug. ***
Comment 22 FiNeX 2011-09-14 20:45:06 UTC
I'm also able to reproduce the bug using KDE 4.7.1:
- recent address are shown on the autocomplete box
- all address on the addressbook are never used

The addressbook is configured as a VCF file on the Akonadi resources list.

From KAddressBook or using the manual address selector on Kmail composer window the addressbook is correctly shown.
Comment 23 Antonio Rojas 2011-09-15 20:14:15 UTC
*** Bug 276762 has been marked as a duplicate of this bug. ***
Comment 24 Paul 2011-09-18 20:32:00 UTC
I can confirm this behaviour in Gentoo running KDE 4.7.1 with Akonadi 1.6.0-r1.

I have a Kolab server with my own Contacts folder and an LDAP server with shared contacts. Both address books are accessed through akonadi.

When I start typing an address, auto-completion works for recent addresses and the shared (LDAP) address book.

However, for my personal contacts, the behaviour is as described earlier in this bug.
Comment 25 Roman 2011-09-21 06:10:40 UTC
KDE 4.7.1, akonadi-server-1.6.0-r1: same bug. autocomlete from LDAP works only for one of two configured LDAP source
Comment 26 Nicolai Haehnle 2011-09-29 08:26:25 UTC
I stumbled across this bug myself recently. Here is the workaround that fixed it for me:

Open System Settings, go to Personal Information. You will see a dialog called "Configure KDE Resources". In the dropdown list, select "Contacts", and Add... the "Akonadi Address Books" resource.

(From what I've read, this "KDE Resources" dialog is reachable via some other path in the System Settings, depending on which version of KDE you are using.)

It seems to me that the (or at least one) real bug here is that I, as a user, have to do this extremely non-obvious step manually. From a user perspective, things should Just Work(tm).
Comment 27 FiNeX 2011-09-29 09:28:02 UTC
@Nicolai: I've both the file resource and the Akonadi one configured in the "KDE resources", moreover the autocompletition priority is configured to use the Addressbook. But it doesn't work :-(
Comment 28 Riccardo Iaconelli 2011-10-18 12:20:26 UTC
i could reproduce this bug and i solved it by removing and adding back the "nepomuk contact feeder" (through akonadiconsole).
Comment 29 Riccardo Iaconelli 2011-10-18 12:21:45 UTC
(p.s.: looking more deeply in the description of this bug, i had the same symptoms of #277403, which might or might not be related)
Comment 30 JK 2011-10-19 07:47:46 UTC
I've recently started experiencing this. When I hit the crash caused by this recent bug: https://bugs.kde.org/show_bug.cgi?id=283615 (it's now fixed), I changed my "standard" akonadi contact resource to a vcarddir resource in trying to fix that bug (obviously did'nt work ;). 

Now, due to this bug: https://bugs.kde.org/show_bug.cgi?id=273949, I cannot set my akonadi contact resource back to the "standard" as before (as the resource is *always* read only). Since then, autocompletion in kmail has stopped. So it would seem that not only must a akonadi contact resource exist, but it must also be set as the "standard". 

All a bit of an unintuitive mess, but I'm sure the good devs will fix it eventually. Thanks for your efforts guys!
Comment 31 Andreas Pietzowski 2011-11-04 21:27:10 UTC
Auto-completion seems to work. But only after the first complete-word-match matches. e.g. the complete forename of a contact.

Isn't this happening to the developers when using kmail? Or what email program do you use? :-)
Comment 32 Paul 2011-11-05 10:25:28 UTC
I can confirm this in KDE 4.7.3 with kdepim 4.7.3. Autocomplete indeed needs a complete word, but at least it works with all addressbooks. For me, this means that the severity could be lower, as it is very workable at the moment, even if it isn't 100%
Comment 33 FiNeX 2011-11-07 09:44:09 UTC
4.7.2 (and with akonadi "correctly" configured): autocompletition work but it show too much suggestions, you start typing "c" and it shown _all_ contacts which matches with .*c.*, you press "a" and the autocompletition list still display _all_ the contacts without filtering...


4.7.3: autocompletition works like expected.


Upgrading to 4.7.3 solved the problem.
Comment 34 Matěj Laitl 2011-11-07 11:28:15 UTC
(In reply to comment #33)
> 4.7.2 (and with akonadi "correctly" configured): autocompletition work but it
> show too much suggestions, you start typing "c" and it shown _all_ contacts
> which matches with .*c.*, you press "a" and the autocompletition list still
> display _all_ the contacts without filtering...

What do you mean by "correctly"?

> 4.7.3: autocompletition works like expected.

Not for me, I have 2 address books (Google Contacts & Personal Contacts) and I got autocompletion only from the Google Contacts one.
Comment 35 FiNeX 2011-11-07 12:45:36 UTC
With "correctly" I mean that the akonadi resource is configured in order to use the correct addressbook and it is _enabled_ :-)
Comment 36 Thomas Zell 2011-11-07 18:42:13 UTC
I have 4.7.3 installed.

I cannot enable the Akonadi address book as 'standard' because it is always read only. I can't get the workaround mentioned above to work (all entries have ReadOnly=false).

There is no auto completion except for the 'recent addresses'. But the 'Select' buttons allows selecting addresses from the Akonadi address book.
Comment 37 JK 2011-11-08 03:19:54 UTC
Same as Thomas Zell. 4.7.3, can't change read only address book and set as standard. Editing ~/.kde4/share/config/kresources/contact/stdrc manually does not work around the issue. No autocompletion. Using "Select" buttons to enter contacts' addresses for now.
Comment 38 Erasmo Caponio 2011-11-09 16:41:26 UTC
I can confirm this bug.
I'm using kde 4.7.3 on kubuntu 11.10.
Comment 39 postdoc38 2011-11-10 13:58:06 UTC
In my experience, autocompletion is a totally unreliable feature so far. Sometimes it works, sometime not. It might be my fault as I update kde regularly (once a week or more), waiting for other long standing bugs to be resolved.

However, autocompletion has always worked for *some* time after wiping all akonadi/nepomuk stuff (see commands below) then redefining all akonadi resources (addressbooks, IMAP resources and the like).

Beware that you will need to reenter all your credentials for all your email accounts, aso. A major pain in the a.. just to get autocompletion working until ...

wiping commands:

rm -rf `find ~/.kde4 -name "*ako*`
rm -rf `find ~/.kde4 -name "*nepo*`

then do the same for ~/.kde, ~/.local and ~/.config
Comment 40 FiNeX 2011-11-16 09:47:34 UTC
btw... I've had to disable nepomuk due to a bug which causes virtuoso to use 100% of CPU, so I cannot use autocompletition again :-(
Comment 41 Murz 2011-11-25 06:21:13 UTC
I expiring this issue too. I have upgraded to KDE 4.7.3 and this is not solve the problem.
I have 3 addressbooks in akonadi:
1. Personal contacts
2. akonadi_googledata_resource
3. VCard file

In KAddressBook all three addressbooks works good, search done normally.

In KMail2 Composer if I press "Select..." button, I also see 3 addressbooks and can search in all.

But in Completion popup I see results only for akonadi_googledata_resource, and nothing from other.

Changing completion order didn't change anything.

So, the bug is in Kmail2 Completion function, not in other parts of kde/akonadi!
Comment 42 ermonnezza 2011-12-02 15:56:21 UTC
I can confirm this in kmail2 4.7.2
For me there's no autocompletion at all, but I can select using the button from all the addressbooks I have
Comment 43 Eggert Ehmke 2011-12-06 11:26:55 UTC
For me the issue is partly resolved. I can select addressbook entries when I type the complete first or second name of a contact. This does not work however, when the typed name contains special characters (german umlaut like äöü)
My system:
Gentoo kernel 3.0.1
KDE/KMail 4.7.3
Comment 44 Alvise 2011-12-11 14:40:35 UTC
Just upgraded to KDE 4.7.4, erased Nepomuk database, recreated KDE resources...
Nope, still no autocompletion except for recent addresses
Comment 45 m.wege 2012-01-07 16:19:11 UTC
It still does not work for me in KDE 4.8 RC2. This is really annoying. Would be nice, if it could be fixed in the release. Is there any way to help making this clearly reproceable since it does not seem to affect all.
Comment 46 Murz 2012-01-08 11:42:10 UTC
Confirm that issue is not fixed on KDE 4.8 RC2.
Comment 47 avlas 2012-01-09 16:14:53 UTC
Same behavior here. I hope it is fixed soon :)
Comment 48 Paul van Erk 2012-01-26 08:16:35 UTC
Yup, broken again, indeed. I had it working in 4.7.3 and 4.7.4 but now 4.8 is borking out again. I enabled 'recent addresses' which has most of them, as clicking the select button and then going through that list is even more work. I don't understand why this keeps on breaking. :( Hope it gets fixed soon, I do like kmail.

(also wish the google contacts akonadi resource would finally work again (had good hopes for 4.8, but it still segfaults), so I don't have to export my contacts to a vcf file, but that's a different issue :) )
Comment 49 Anders Lund 2012-01-28 18:22:27 UTC
After finally taking on kmail2, I got hit by this. My addressbook is in good shape, akonadi resource is set as standard addressbook, all my contacts and groups are in there, but it does not work.

The dialog for selecting contacts works, but not autocompletion.
Comment 50 FiNeX 2012-01-28 20:21:26 UTC
I didn't tested it on KDE 4.8 because I've disabled nepomuk due to an aggressive use of CPU :-(
Comment 51 Cédric Bellegarde 2012-01-30 08:27:08 UTC
Same here, it works for:
- LDAP
- recent address
 
but not for akonadi contacts... It works with krunner contact plugin.
Comment 52 GK 2012-01-31 16:38:15 UTC
The auto-completion does not work at all in KDE 4.8, Kubuntu 11.10. All settings in address books, resources, etc are set correctly. Also Kmail settings for autocompletion is set. But does not work even after restarting the whole lot.
Comment 53 Paul 2012-01-31 19:12:13 UTC
Unfortunately, I can confirm the same for KDE 4.8 on Gentoo. The only thing that still works for me are recent addresses. No autocompletion from any address books at all.
Comment 54 Ralph Moenchmeyer 2012-02-04 14:25:49 UTC
I updated to KDE 4.8 on Opensuse 12.1. My addressbook is an open-xchange 6 ressource. Autocompletion for this address book worked at least partially in KDE/Kmail 4.7.4. Partially in the sense that the pattern recognition did not work reliably.  

Autocompletion stopped working completely in Kmail 4.8. I tried also a complete new installation of KDE 4.8 on a different machine. Same result.

The address book itself, however, works fine and search functionality in Kontact/Addressbook is working flawlessly, too. It is "only" the autocompletion mechanism in Kmail that is not working.
Comment 55 Henning Becker 2012-02-05 07:57:52 UTC
(In reply to comment #54)
> I updated to KDE 4.8 on Opensuse 12.1. My addressbook is an open-xchange 6
> ressource. Autocompletion for this address book worked at least partially in
> KDE/Kmail 4.7.4. Partially in the sense that the pattern recognition did not
> work reliably.  
> 
> Autocompletion stopped working completely in Kmail 4.8. I tried also a complete
> new installation of KDE 4.8 on a different machine. Same result.
> 
> The address book itself, however, works fine and search functionality in
> Kontact/Addressbook is working flawlessly, too. It is "only" the autocompletion
> mechanism in Kmail that is not working.

Same behaviour here, also in openSuSE 12.1 with KDE SC 4.8.

I'm using CalDAV/CardDAV-Akonadi-Resource to manage my contacts and calendars and tried to select my current addressbook in KDE resources menu, but my calendar resource does not show up. So I cannot test, if it helps to select the correct addressbook.

Greets,
Henning
Comment 56 Andreas Pietzowski 2012-02-06 22:35:10 UTC
Same here with 4.8 on Kubuntu 11.10. No auto-completion at all. Please fix this. Composing messages is really a very hard job with that bug existing. Should not be so hard to fix I guess.
Comment 57 Sérgio Basto 2012-02-06 22:51:53 UTC
from #c8 , not ASAP but just with complete name, I got entries from address book .
Comment 58 postdoc38 2012-02-07 06:18:35 UTC
@andreas: don't forget autocompletion uses the new iliketomessup framework which is great as it can also be used to transform water into beer. Unfortunately, the beer component is ... well not completely ready yet, and I'd rather the devs work on that, as I'm sure there is a big market for it, even if in the mean time, I'll have to make with an indexer using 100% of my CPU forever...
Comment 59 Paul Gideon Dann 2012-02-07 06:51:18 UTC
@postdoc I think you'll find that the sarcasm doesn't do you any favours.  If you were creating something this big and not getting paid for it, and someone came along all sarcastic and started yelling at you, do you think you'd want to fix that guy's bug?

The frustration is understandable, but please vent somewhere out of sight, where you won't be angering the very people we want to do us a favour!
Comment 60 Paul van Erk 2012-02-07 07:34:02 UTC
(In reply to comment #57)
> from #c8 , not ASAP but just with complete name, I got entries from address
> book .

Are you sure about that? I have a vcf file I use as an address book (Google contacts export, until the Google Contacts akonadi resource will work :) ) and only the people in there that I have e-mailed before will appear (well, their e-mail address) and not people I never sent an e-mail. So for me it's the original bug: resource autocomplete doesn't work, only 'previously e-mailed addresses' will appear.
Comment 61 m.wege 2012-02-07 07:48:59 UTC
I wonder why no Kmail-developer has ever commented on it. May be the problem is that although it is a Kmail-bug, the problem is rather related to Kaddressbook and there for the bug is not correctly assigned. Otherwise I wonder if the bug is not clearly reproducable (thus Kmail devs do not have the problem) and if there is a way those affected by the bug could help to make it reproducable.
Comment 62 Andre Heinecke 2012-02-07 08:34:35 UTC
Well what happens there is that Kontact uses Ldap/Recent Addresses and Nepomuk for addressee completion.
So if you only have Ldap and Recent entries you are looking at a problem with either Nepomuk or the Nepomuk Contact feeder.
KAddressbooks search works a bit different as it just pulls all the addresses you have (which is not such a good idea for the mailcomposer) and then searches on them.
I personally don't have Nepomuk (i'm on Windows) but I looked into this problem a bit as this is really annoying when you don't have nepomuk available. 
If you have Nepomuk I think it the comment from #28 (remove akonadi_nepomuk_contact feeder) and adding it again might do the trick if it causes the contacts to be reindexed.

The bug here is "The code assumes a working and valid nepomuk search service with indexed contacts" and as there are still loads of problems with nepomuk this assumption can not always be fulfilled. :(
Comment 63 Riccardo Iaconelli 2012-02-07 11:53:47 UTC
So, while at FOSDEM, I've asked PIM developers in person, and it looks like yes, this bug is going to be fixed very soon. This bug looks like a side effect of another big bug in virtuoso (the one where it takes 100% CPU) and so, hopefully, when it's resolved a lot of other KDE annoyances will go away, too.

I don't know about the time frame, but my guess is that it will happen in a month or so. A good thing is that PIM developers know and care about it.

(as a sidenote: the workaround that I previously mentioned in #28 doesn't work anymore in 4.8...)
Comment 64 Paul van Erk 2012-02-07 12:18:41 UTC
Awesome, thanks for that information. Hoping for 4.8.1 then. Serves me right to use the newest stable. ;)
Comment 65 rich.peiffer 2012-02-07 14:56:48 UTC
Recently upgraded to kde 4.7.4.  Have had no issues with the address book in the past.  Noticed auto complete from "recently used" still works, but nothing from the address book.  Checked my address book - looks good.  Can use the "select" button in kmail composer - addresses still come up.

Did further research and have read that the auto complete determines where to look based on system setup > kde resources.  Under type "contacts" I have both a "dir-resource" pointing to the address book, and there is an akonadi-resource pointing to the address book resource I have configured (which is working with the address book / contact manager).

I noticed, under the kde resources screens, cannot make the akonadi-resource "standard".  When I do, I get "cannot use read-only resource as standard.  Go into the resource and edit, uncheck "read only", save, no error.  Try again to set as standard, same message, go back into the resource and it still has the read only box check - cannot remove it.  Checked the Akonadi resource for the address book under "akonadi resources configuration", and the address book entry is NOT checked read-only.

OK.  The problem with Akonadi, read only issue is documented in 273949.  Are these two related???  Is it because I can't make the akonadi based resource the "standard"?  Is there any workaround to this?
Comment 66 Anders Lund 2012-02-07 15:42:03 UTC
If this has to do with the virtuoso problems, it is very odd that the addressee selection dialog filters immediately, no problems at all, ever. Aren't they using the same technology? if not, then why not?
Comment 67 Ralph Moenchmeyer 2012-02-07 16:04:53 UTC
I think Anders Lund (comment #66) has a good point. All address selection dialogs in the address book part of Kontact as well as in the Kmail part of Kontact work perfectly well - also with OX 6 address resources accessed via Akonadi.

Actually, as a workaround for the buggy address completion I now use the selection dialog in Kmail to define the receiver addresses. And this works fast and reliable.
Comment 68 Hannes Kuhnert 2012-02-07 16:15:02 UTC
(In reply to comment #66)
> If this has to do with the virtuoso problems, it is very odd that the
> addressee selection dialog filters immediately, no problems at all, ever.
> Aren't they using the same technology? if not, then why not?

The selection dialog uses a direct Akonadi access, just like KAdressbook.

I also don’t know, why the autocompletion relies on Nepomok, but I assume that Nepomuk provides a handy support for autocompletion in text fields.
Comment 69 Andre Heinecke 2012-02-07 16:45:45 UTC
Well kaddressbook and the addresse selection editors basically obtain a copy of all your contants, put them in a model and filter on them.
For small contact sets this is quicker but it does not scale so well and for huge address books this is overhead.

I would rationalize "We have a very quickly searchable index available in Nepomuk so let's use it for this and only fetch the contacts we really need"

I have to admit, this is currently a pretty bad state (Especially on Windows where we don't have Nepomuk at all) and there should be a fallback especially as the code can mostly be reused from the emailaddresseeselectionwidget and Kaddressbook. But the main discouraging point is to increase ressource usage and complexety just to work around problems which will be solved eventually.
Comment 70 Ralph Moenchmeyer 2012-02-07 17:22:29 UTC
(In reply to comment #69)
> 
> I have to admit, this is currently a pretty bad state (Especially on Windows
> where we don't have Nepomuk at all) and there should be a fallback especially
> as the code can mostly be reused from the emailaddresseeselectionwidget and
> Kaddressbook. But the main discouraging point is to increase ressource usage
> and complexety just to work around problems which will be solved eventually.

Thank you for explaining. I want to point out that in KDE 4.7.4 the autocompletion worked at least partially. I got a reasonable list when I e.g. only typed one letter or typed a full word until a separation letter like a dot. E.g. I typed "a" or "alpha" and all adresses with alpha.xxxx@yyyy.zz appeared. What did not work, was an input like "alp" for these cases. Compare to comment #57. 
And I cannot remember that there was a problem in version KDE 4.7.2 or 4.7.3 at all. See also comment #65 or comment #33. However, I do remember that when upgrading to 4.7.2 or 4.7.3 I had to delete all nepomuk related configuration files first to get everything working (which you have to do in KDE 4.8, too, to get rid of the annoying CPU consumption for email reindexing).     

Maybe that helps to analyze the problem.
Comment 71 Anders Lund 2012-02-07 19:08:46 UTC
The nepomuk solution is only good if it works, but in KDE 4.8 it is broken. NO addressbook contacts show up in the completion, ONLY recent addresses. Not ever, so it can not have todo with the cpuspiking trouble- it doesn't work no matter the state of virtuoso-t, which is btw in a good state most of the time here.
Comment 72 Sérgio Basto 2012-02-07 22:39:31 UTC
yeah after lastest update of virtuoso-opensource on Fedora 16 I don't remember see virtuoso at 100% of CPU , but not confirm .
on kdepim Mailing List we talk about a bug on address with accents , and after update and rebuild  nepomuk from scratch , I have addressbook /home/sergio/.kde/share/apps/kabc/std.vcf searching but only all word. 

in this thread: [kdepim-users] kmail2 search doesn't work, 
http://lists.kde.org/?l=kdepim-users&m=132473583632465
have what I did to repopulate nepomuk and akonadi. 
be warned that is not a safe thing.
Comment 73 Boris Bigott 2012-02-13 09:11:09 UTC
I have the same problem with the kmail version shipped with KDE 4.8.0. Address auto-completion does only work for recent addresses. Interestingly, using the select button to search addresses works flawlessly. I think this is a serious regression because it worked in KDE 4.7 for me.
Comment 74 steve 2012-03-01 22:28:59 UTC
Same problem here. I've tried everything and I can't make it happen.

Kubuntu 11.10 KDE 4.8
Comment 75 wuselwu 2012-03-02 03:37:17 UTC
This seems to go on for years :(. Is it so difficult to get a basic comfort functions probably every other email client out there has back into the akonadi-based kmail?
Comment 76 Al 2012-03-02 04:55:08 UTC
Can the OP change the 'Severity' to "Major",

 https://bugs.kde.org/page.cgi?id=fields.html#bug_severity
 Major 	major loss of function

Loss of standard addressbook completion seems to qualify as "major loss of function".

Maybe that plus the #8 position on the "Most Hated Bugs" will get somebody to join in that can help.
Comment 77 Philipp Woelfel 2012-03-02 06:14:58 UTC
I wouldn't get my hopes up. In 2nd place on the list of most hated bugs is one that is more than 3 years old: 
https://bugs.kde.org/show_bug.cgi?id=180051

Too bad that there is no information from the PIMS developers.
Comment 78 steve 2012-03-02 14:10:11 UTC
The bug is severe enough for me to be greatly hindered in using Kmail for my business, which I've been doing for years now. It is too much to hand select emails from 1500 clients. So yesterday I wiped my drive and installed Kubuntu 11.10 fresh. I went ahead and let it perform the first set of updates suggested by the system. I believe this updated from 4.7.3 to 4.7.4. I created a new personal contact book using akonadi, and populated it with Vcard import in Kontact. Autocomplete works flawlessly now.

It seems something breaks in either Nepomuk feeder or Akonadi when upgrading to a new 'decade' of KDE. I am witholding implementing anymore system updates for now because this is a feature of Kmail I must have. I spent quite a while searching around for clues and found many people experiencing this bug who have yet to report it. I consider it a major bug.
Comment 79 Al 2012-03-02 23:18:38 UTC
@Philipp Woelfel
> I wouldn't get my hopes up. In 2nd place on the list of most hated bugs
> is one that is more than 3 years old

Wow, I didn't realize how bad it was.

Like other users here, fully-working email is not an option for me.  I don't know of any other option that's KDE-integrated other than KMail.  Downgrading to KDE v4.7.4 sounds like it works, but imo that's not a great option if this sort of thing happens a lot.

I tried to get some attention on this and got yelled at asking about this in irc and got the usual "we do it for free" and "fix it yourself" lectures :-(

I just installed Thunderbird to check it out.    So far,   everything seems to work in Thunderbird -- and it's a LOT faster. It doesn't integrate with KDE as much, but if that doesn't work anyway, it doesn't matter all that much.
Comment 80 Achim Bohnet 2012-03-03 09:11:20 UTC
If you're  affected, please add your vote, but keep discussions on the corresponding forum entry:

https://forum.kde.org/viewtopic.php?f=215&t=99398&hilit=kmail+4.8+address+composer

Information that helps to find out what's wrong since 4.8 add it here.

See e.g.,
http://blog.martin-graesslin.com/blog/2012/02/how-we-could-use-bugzilla-for-user-support/

why that's( IMO) a good idea. 

As soon as I 've more time I'll try to kontact the developer to find out how we can produce useful debug info to nail down the problem.  Feel free to be faster :)

Achim
Comment 81 Øystein Olsen 2012-03-09 09:56:33 UTC
I have some additional information, that may or may not help. I have configured an ldapkio in system Settings -> Personal Information -> KDE Resources. I can now hit Alt-F2 and find contacts by typing part of their names.

However, auto-completion  does not work  in kmail, but  I have found a way to make this work in kmail. I have an old kabldaprc configuration that I happened to place in ~/.kde4/share/config and suddenly auto-completion started to work with LDAP in kmail (KDE 4.8.1). 

 Does the auto-completion still use old-style KDE resources?
Comment 82 Jan Hackel 2012-03-09 10:21:12 UTC
In my '~/.xsession-errors' file appear several nepomuk related errors while typing into the address field. From what I gather, it is not the actual search which fails but the retrieval of the found items.

When I type "Andr" for the first three keystrokes there will be errors like:

/usr/bin/nepomukservicestub(4947)" Soprano: "SQLExecDirect failed on query 'sparql prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE {   graph ?g {     ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId .     ?group nco:contactGroupName ?v .     ?v bif:contains "'And*'"  } }' (iODBC Error: [OpenLink][Virtuoso iODBC Driver][Virtuoso Server]FT370: Wildcard word needs at least 4 leading characters)"

Ok, nepomuk needs at least four characters before actually doing a search. These errors cease with the fourth character. Instead I get something like this:

[/usr/bin/nepomukservicestub] "/usr/bin/nepomukservicestub(4947)" Soprano: "SQLExecDirect failed on query 'sparql SELECT DISTINCT ?r ?reqProp1 WHERE { nepomuk:/res/d7e1e2fa-1e49-461f-b8a4-af8c95f99777 a ?v2 . nepomuk:/res/d7e1e2fa-1e49-461f-b8a4-af8c95f99777 <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . } LIMIT 1' (iODBC Error: [OpenLink][Virtuoso iODBC Driver][Virtuoso Server]SQ074: Line 1: SP030: SPARQL compiler, line 1: Undefined namespace prefix at 'nepomuk' before '/')"

That seems to be a query for an individual item, most probably a contact. I suppose all the strings starting with "nepomuk" should be bracketed in '<>' . At least I get a result when doing such an query using the command line 'sopranocmd --dbus org.kde.NepomukStorage --model main query ' followed by such a bracketed query.

Using: KDE 4.8.1 on gentoo.
Comment 83 quazgar 2012-03-20 22:43:52 UTC
For me, the problem seems to have to do with the akonadi-server version:

On Gentoo, 1.6.2-r1 works more or less (after one full part of the name has been completely written), whereas 1.7.1 shows really only the recent addresses, as experienced by many people here.
Comment 84 Richard Homonnai 2012-03-20 22:46:33 UTC
(In reply to comment #83)
> For me, the problem seems to have to do with the akonadi-server version:
> 
> On Gentoo, 1.6.2-r1 works more or less (after one full part of the name has
> been completely written), whereas 1.7.1 shows really only the recent
> addresses, as experienced by many people here.

Well, also on Gentoo, 1.6.2 did not work either for me. So it might be something else.
However! I think I might have had installed 1.7.1 already before (I remember downgrading after akonadi-server finally got stable)
Comment 85 quazgar 2012-03-30 20:43:17 UTC
Any hint if and what this akonadi output (also mentioned in bug 277403) may have to do with the problem? It appears at every letter I enter in the address field:

Could not contact query service. 
QStringList Akonadi::NepomukSearch::search(const QString&) Calling blockingQuery() failed!
Comment 86 quazgar 2012-04-01 13:56:31 UTC
Ok, it seems I got my Akonadi working a bit better now, but this is what I get on Akonadi's console output:

void Nepomuk::Query::QueryServiceClient::close() 
void Nepomuk::Query::QueryServiceClient::close() 

 (For each letter until the first part of the name has been completed.)

Failed to get requested akonadiItemId property 
AkonadiItemId missing in query results!  QUrl( "akonadi:?item=19" )  false false false QVariant:: 0 
Failed to get requested akonadiItemId property 
AkonadiItemId missing in query results!  QUrl( "akonadi:?item=23" )  false false false QVariant:: 0 
void Nepomuk::Query::QueryServiceClient::close() 
Failed to get requested akonadiItemId property 
AkonadiItemId missing in query results!  QUrl( "akonadi:?item=726" )  false false false QVariant:: 0 
void Nepomuk::Query::QueryServiceClient::close() 
Failed to get requested akonadiItemId property 
AkonadiItemId missing in query results!  QUrl( "akonadi:?item=722" )  false false false QVariant:: 0 
void Nepomuk::Query::QueryServiceClient::close() 
void Nepomuk::Query::QueryServiceClient::close() 
void Nepomuk::Query::QueryServiceClient::close() 
void Nepomuk::Query::QueryServiceClient::close() 

(For the last letter which then completes the first part of the name.)
Comment 87 quazgar 2012-04-01 14:51:09 UTC
@nepomuk/akonadi devs: Could it be that this commit should fix the bug, at least for some people?
https://bazaar.launchpad.net/~neon/akonadi/master_old/revision/1834
Comment 88 Franz Trischberger 2012-04-01 15:27:39 UTC
I applied the patch, and for me it did NOT fix the problem - still no autocompletion of mail addresses.
Comment 89 Michael F. 2012-04-05 12:00:07 UTC
I just updated my gentoo-box to KDE 4.8.2 (including kmail2) and the bug ist still present. Is the "big bug" mentioned in comment #63 fixed in 4.8.2? If not, I guess we have to wait for this to happen.
Comment 90 Cédric Bellegarde 2012-04-05 12:10:39 UTC
Can confirm: fail with KDE 4.8.2 on ArchLinux
Comment 91 Paul van Erk 2012-04-05 12:12:36 UTC
openSUSE with 4.8.2 and updated Qt: same story
Comment 92 Philipp Schmidt 2012-04-05 12:40:42 UTC
Could we please agree that posting "Still present" and "me too" for every point-release of KDE SC just spams everyones mailbox? It doesn't help with fixing the bug, it doesn't motivate anyone to help, it is just annoying (We can all see it in our daily workflow that the bug is still present). Please comment if you have a Fix or if the Bug has been fixed.

Thank you (also on behalf of my mailbox)!

PS: If you want to discuss this opinion of mine, please do so on the KDE Forums and not here.
Comment 93 Paul Sobey 2012-04-11 09:19:14 UTC
All, on Gentoo here with KDE 4.8.2. I've had this problem with 4.8.*. As far as I can tell, upgrade to akonadi 1.7.2 (hit the tree several days ago) appears to have fixed this issue for me.
Comment 94 Cédric Bellegarde 2012-04-11 09:31:18 UTC
Here, KDE 4.8.2 and Akonadi 1.7.2...

Bug always here: No local contacts, no akonadi-google contacts... Only recents and LDAP contacts...
Comment 95 Paul Sobey 2012-04-11 09:34:23 UTC
Ah, I'm doing LDAP via GSSAPI to a Windows 2008 Active Directory. Was working pre 4.8, is now working again perfectly.
Comment 96 Paul 2012-04-13 07:51:52 UTC
Running Gentoo with
kmail 4.8.2
akonadi server 1.7.2
personal and shared address book, both on kolab groupware server

Things seem to have improved here since either the latest KDE or akonadi upgarde, which I did on 5 and 8 april. I now have the functionality that I had in KDE 4.7:

- Autocomplete with every keystroke works only on recent addresses
- Once I type a complete name (either first or last) I get search results from all addressbooks
- After a name was found once (in either of the previous 2 possibilities) it shows up after relevant keystrokes

The last point is only during a kontact session. Once I close and restart I have to type a complete name to find a contact in one of my address books.

One last point, I just noticed that my address books had both been disabled for some reason after the last upgrade, so first I had to tick the boxes again.
Comment 97 Joachim Wilke 2012-04-17 16:23:01 UTC
Chakra Linux with KMail 4.8.2 and akonadi 1.7.2.

After upgrading akonadi from 1.7.1 to 1.7.2 and purging the nepomuk database in ~/.kde4/share/apps/nepomuk address completion works like described in comment #96. 
Also searching messages in KMail works now.

In System Settings -> Configure KDE Resources I have *not* set up akonadi-resource as the default contact resource.
Comment 98 nulll 2012-04-27 15:49:08 UTC
Kubuntu 12.04 fresh install
KDE 4.8.2
Kmail 4.8.2

I can't set an akonadi-resource as a default
systemsettings > personal info > kde resource
I think because of this bug
https://bugs.kde.org/show_bug.cgi?id=273949

I can see my contacts in kadressbook, 'cause I imported my contacts inside the
systemsettings > personal info > akonadi > "personal contacts"
(~/.local/share/contacts)

But the kmail autocompletion seems to work only on "recent emails" and on "personal contacts" manually created after the import.

This is very frustrating and complicated.
Please, can anyone help me having kmail autocompletion working with all my "personal contacts"?
Comment 99 Joachim Wilke 2012-05-03 08:17:14 UTC
See comment #97, do you have akonadi 1.7.2?
Comment 100 nulll 2012-05-03 09:47:04 UTC
Can you please tell me how to know what is my akonadi version?
Thanks!
Comment 101 Paul 2012-05-03 09:54:49 UTC
with this command

akonadiserver --version
Comment 102 nulll 2012-05-03 10:15:49 UTC
Akonadi 1.7.2
Comment 103 Joachim Wilke 2012-05-03 10:29:12 UTC
Try to purge nepomuk database in ~/.kde4/share/apps/nepomuk (see above) and let nepomuk_contact_feeder complete. Then try again.
Comment 104 nulll 2012-05-03 11:01:44 UTC
"Try to purge nepomuk database in ~/.kde4/share/apps/nepomuk"
i just have to "rm -r ~/.kde/share/apps/nepomuk" ?

"let nepomuk_contact_feeder complete"
how to know when this event occoures?

thanks for your help
Comment 105 Cédric Bellegarde 2012-05-03 13:10:53 UTC
Do i need to activate email indexer in nepomuk ?
Comment 106 Cédric Bellegarde 2012-05-03 13:32:57 UTC
Here, it seems to fail because in akonadiconsole, Akonadi Nepomuk Feeder is always marked as: "System Busy, indexing suspended" ... So, no mail indexing, no contact indexing, no calendar indexing...
Comment 107 Ctibor Brančík 2012-05-03 18:06:43 UTC
On my system I get this error message in soprano-virtuoso.log:

20:03:13 compiler text card estimate got error 22023 FT370: Wildcard word needs at least 4 leading characters, assuming unknown count
Comment 108 Joachim Wilke 2012-05-03 18:22:52 UTC
"How to know when this event occoures?"
Have a look at akonadiconsole. There Nepomuk Contact Feeder should report "Indexing completed".

If "System busy indexing suspended" appears permantently, try to modify .kde4/share/config/akonadi_nepomuk_feederrc by adding 

[akonadi_nepomuk_feeder]
DisableIdleDetection=true
Comment 109 nulll 2012-05-04 07:16:55 UTC
I purged the nepomuk db doing
rm -r ~/.kde/share/apps/nepomuk

I let nepomuk re-index all the stuff, nepomuk says "indexing complete"

kmail is still not using kaddressbook for autocompletition

I' moving to thunderbird, in my opinion the nepomuk+akonadi+kontact is not ready, it's a mess, i think it should be release as alpha softare or similar
Comment 110 Joachim Wilke 2012-05-04 07:21:48 UTC
Works great here using same steps. However have fun with TB. ;)
Comment 111 Cédric Bellegarde 2012-05-04 07:44:40 UTC
It was working some days ago here...

I switch from google-akonadi to webdav-akonadi and no completion anymore... There is something buggy, but hard to find what...
Comment 112 Erwin Van de Velde 2012-05-10 15:21:51 UTC
The bug persists in KDE 4.8.3, perhaps a fix in 4.8.4? :-)
(using akonadi-google)
Comment 113 Cédric Bellegarde 2012-05-15 11:07:23 UTC
Hmm, it works here... 

It was just another akonadi bug :-/
https://bugs.kde.org/show_bug.cgi?id=299482
Comment 114 Dimitrios Glentadakis 2012-05-31 15:03:47 UTC
It means that the auto completion works in 4.8.3 ?
I have kde 4.8.2 and the autocompletion works only for the recently used address and not for the addresses present in the akonadi contacts.
Comment 115 Sérgio Basto 2012-05-31 15:36:00 UTC
https://bugs.kde.org/show_bug.cgi?id=259949#c97
Comment 116 Rettich 2012-05-31 16:03:53 UTC
Would be nice, if there is another way than purging the nepomuk database, since that means that I will loose all my tags.
Comment 117 Maf. King 2012-05-31 18:16:50 UTC
(In reply to comment #116)
> Would be nice, if there is another way than purging the nepomuk database,
> since that means that I will loose all my tags.

Doesn't work for me on KDE 4.8.3 (OpenSuSE 12.1 with KDE repository from Factory)

Tried purging the neopmuk and akonadi stuff as outlined in this thread, ended up losing mails as mailboxes got the wrong expire settings as the caches rebuilt themselves. And still address matching didn't work.

Only auto complete that works for me is the recently used addresses, if I want an addressbook entry I have to use the "Select" button at the side of the To: field.
Comment 118 Richard Homonnai 2012-05-31 18:22:27 UTC
(In reply to comment #117)
> (In reply to comment #116)
> > Would be nice, if there is another way than purging the nepomuk database,
> > since that means that I will loose all my tags.
> 
> Doesn't work for me on KDE 4.8.3 (OpenSuSE 12.1 with KDE repository from
> Factory)
> 
> Tried purging the neopmuk and akonadi stuff as outlined in this thread,
> ended up losing mails as mailboxes got the wrong expire settings as the
> caches rebuilt themselves. And still address matching didn't work.
> 
> Only auto complete that works for me is the recently used addresses, if I
> want an addressbook entry I have to use the "Select" button at the side of
> the To: field.

I can confirm this - Gentoo amd64 stable. Purging didn't help at all.
Comment 119 Dimitrios Glentadakis 2012-05-31 18:39:37 UTC
For me, deleting the nepomuk folder did nt help.
I open the akonadi resources in systemsettings and i added a new resource from google-contacts, and i deleted older resources from google but with other names(!). I did some other changes in akonadi resources and in akonadiconsole without knowing what i do. 

* I did a logout from kde and now the autocompletion work but only if i type the whole name of the contact.

This has fixed (until now...) another problem that i have with the password: https://bugs.kde.org/show_bug.cgi?id=300933

Unefortunately i am not capable to say what i did (many clicks in several names (agents), deletion of many of them etc.) , i dont understand the set of nepomuk-akonadi, and what they do in my system, not the role of the programs but their elements in my system which i discover every time in several places with different names.

Good luck !
Comment 120 Sérgio Basto 2012-05-31 18:43:29 UTC
https://bugs.kde.org/show_bug.cgi?id=259949#c97 
DOESN'T TALK JUST ABOUT PURGE , talks about you *need* upgrade akonadi 
"After upgrading akonadi from 1.7.1 to 1.7.2 .... "
Comment 121 Hannes Kuhnert 2012-05-31 19:01:47 UTC
(In reply to comment #119)
> For me, deleting the nepomuk folder did nt help.
> I open the akonadi resources in systemsettings and i added a new resource
> from google-contacts, and i deleted older resources from google but with
> other names(!).

BTW, naming is irrelevant AFAIK. The resources of every type are identified by sequentially assigned numbers. For example, if you deleted “akonadi_maildir_resource_1” no Maildir resource will ever again get #1 in this Akonadi environment.

> * I did a logout from kde and now the autocompletion work but only if i type
> the whole name of the contact.

Without reconfiguring anything I sometimes have it working that way in KDE 4.8.3, but that’s really only once in a while and I have no idea for what reason it sometimes works and sometimes not.
Comment 122 Maf. King 2012-05-31 19:09:17 UTC
(In reply to comment #120)
> https://bugs.kde.org/show_bug.cgi?id=259949#c97 
> DOESN'T TALK JUST ABOUT PURGE , talks about you *need* upgrade akonadi 
> "After upgrading akonadi from 1.7.1 to 1.7.2 .... "

maf@calufrax:~> akonadiserver --version
Akonadi 1.7.2
maf@calufrax:~> kmail --version
Qt: 4.8.1
KDE Development Platform: 4.8.3 (4.8.3)
KMail: 4.8.3

Then I followed the procedure in #39 to remove all akonadi and nepomuk cache info.

All addresses locally stored, no LDAP or Google etc to get in the way.

Waited for indexing to finish. Still no addressbook lookups in kmail, and a borked kmail config as a nice bonus, too.  Mostly recovered lost email from backups, but still too much grief to consider trying to flush nepomuk again.  Waiting for either SuSE 12.2 or KDE SC 4.9 to try a fresh install.
Comment 123 Dimitrios Glentadakis 2012-06-03 06:54:32 UTC
(In reply to comment #121)
> (In reply to comment #119)
> > For me, deleting the nepomuk folder did nt help.
> > I open the akonadi resources in systemsettings and i added a new resource
> > from google-contacts, and i deleted older resources from google but with
> > other names(!).
> 
> BTW, naming is irrelevant AFAIK. The resources of every type are identified
> by sequentially assigned numbers. For example, if you deleted
> “akonadi_maildir_resource_1” no Maildir resource will ever again get #1 in
> this Akonadi environment.
> 
> > * I did a logout from kde and now the autocompletion work but only if i type
> > the whole name of the contact.
> 
> Without reconfiguring anything I sometimes have it working that way in KDE
> 4.8.3, but that’s really only once in a while and I have no idea for what
> reason it sometimes works and sometimes not.

You have right because now it does nt work again. Waiting for a fix ...
Comment 124 Erasmo Caponio 2012-06-05 17:00:53 UTC
I've noticed that after configuring once the completion order (right click on the address field "to" and then click to "configure completion order" in the menu to open the configuring window) the same configuration window becomes blank at a second try and  kmail mail starts to become slow (for example: the message "Retriving folder contents. Please wait..." hangs on for a few seconds, deleting a message requires seconds and so on). This slowness does not disappear shutting down kmail or akonadi or restarting the system. I've  gotten  back kmail a normal speed of work suddenly, without a reason that I can understand.
Comment 125 Joachim Wilke 2012-06-06 06:11:38 UTC
I also suffered from a sluggish behaviour (like that in #124) several times, that appeared on
- message retrievel
- message operations (delete, reply, ...)
- sending of new messages (window grayed out for several minutes)
- no autocompletion anymore
but I could not identify a cause. But maybe there is already a spearate bug for this, I'm not convinced this is related to this bug report.
Comment 126 Sérgio Basto 2012-06-08 05:23:23 UTC
I try debug others problem following : 
http://kdeatopensuse.wordpress.com/2011/11/09/debugging-nepomukvirtuosos-cpu-usage/

but this document show some tricks that can help debug here .

open kdebugdialog for example.
Comment 127 Tamás Németh 2012-06-08 13:53:21 UTC
296050 Seems to be the duplicate of this bug. KDE 4.8.3 is still affected.
Comment 128 Tomás Bautista 2012-06-13 10:13:05 UTC
I am using a Ubuntu 12.04 quantal system and I must say that the last week it suddenly worked with KDE 4.8.3, but now with KDE 4.8.80 is not working once again...
Comment 129 Ctibor Brančík 2012-06-13 18:45:43 UTC
Finally works for me in kde 4.8.80 and with akonadi-server 1.7.2.
Comment 130 Maf. King 2012-06-15 07:09:04 UTC
Works for me too using 4.8.80 from the OpenSuSE unstable repository.  
Matching results in the address book are offered after about 3 or 4 characters are typed in.
Not sure about how the results are pesented though, or indeed where some of the matches come from as they don't look familiar to me.  Will investigate some more during the next week or two.
Comment 131 Maf. King 2012-06-15 08:38:58 UTC
No, sorry, I got that wrong.  Still got some breakage going on in 4.8.80 (4.9 Beta1)
More addresses are returned now than under 4.8.3, under the new grouping "contacts found in your data" which seems to be looking at email headers as a source of addresses (this is not "recent addresses" because that also comes up as a heading, with some different suggestions) - btw. can we have an option to turn that new grouping off, please, as it seems to be picking up mostly spammer addresses as suggestions that aren't already in the "recent" list....

Still not getting suggestions from my addressbook data.  If I feel brave, I might try to purge nepomuk/akonadi again, but that may wait until 4.9 (or an RC at least) is out.
Comment 132 Mathias Homann 2012-06-17 07:46:14 UTC
kde 4.8.4, bug still exists.
Comment 133 Cédric Bellegarde 2012-06-18 09:40:55 UTC
KDE 4.9 beta2, bug always here...

It works with a fresh account (no ~/.local/share/akonadi and no ~/.kde/share/apps/nepomuk)...

But it fails as soon:
- You change settings in akonadi (remove ressources, readd ressources, ...)
- Clean nepomuk database, it get never indexed again
Comment 134 Dimitrios Glentadakis 2012-06-18 09:51:48 UTC
Me too, when i deleted everything in my /home (akonadi folders, nepomuk...) it worked but only if i typed the whole name. After a couple hours it stopped working and now it works only the recent addresses but only if i type the address, if i type the name of the contact it dioes nt work
(KDE 4.8.2)
Comment 135 Jeroen van Meeuwen (Kolab Systems) 2012-06-21 08:44:01 UTC
I can confirm this bugs exists still in 4.9 pre - setting version accordingly
Comment 136 m.wege 2012-06-21 09:07:48 UTC
I really wish this bug enough priority so that would be fixed for the release of KDE 4.9. It is very enoying and I have to admit that for most of time I am using Thunderbird now. Mainly because of this bug (partly also because Kmail is still very slow (much faster than in the beginning, but very slow compared to Thunderbird)). And I really would prefer a KDE integrated mailer.
Comment 137 Joachim Wilke 2012-06-21 09:10:03 UTC
You first need to investigate a cause and a patch to fix it... Votes show that this is important for the users.
Comment 138 Christian Mollekopf 2012-06-21 10:45:09 UTC
The cause seems to be the indexer not doing it's job properly. For all indexed items for which I tried so far, autocompletion is working (with 4.9 that is).
As a workaround, to reindex everything, set InitialIndexingComplete to false in .kde4/share/config/akonadi_nepomuk_feederrc.
Comment 139 Sérgio Basto 2012-06-21 17:58:24 UTC
(In reply to comment #138)
> As a workaround, to reindex everything, 

What do you mean with "reindex everything" ? 

>set InitialIndexingComplete to false
> in .kde4/share/config/akonadi_nepomuk_feederrc.
Comment 140 Jeroen van Meeuwen (Kolab Systems) 2012-06-21 18:19:08 UTC
(In reply to comment #139)
> (In reply to comment #138)
> > As a workaround, to reindex everything, 
> 
> What do you mean with "reindex everything" ? 
> 

I think what he means is "to cause akonadi to feed nepomuk for all existing contacts"
Comment 141 Vojtěch Zeisek 2012-06-24 21:30:08 UTC
For me, it works only with recently used addresses. And the it searches only within e-mail (not within name). So it does not work at all. I have all address books provided by Akonadi Google resource and within KAddressBook I see everything as expected. I tried it in openSUSE 12.1, KDE 4.7.2 and 4.8.4. Nepomuk is working properly.
Comment 142 Nico Kruber 2012-07-04 10:23:09 UTC
(In reply to comment #138)
> The cause seems to be the indexer not doing it's job properly. For all
> indexed items for which I tried so far, autocompletion is working (with 4.9
> that is).
> As a workaround, to reindex everything, set InitialIndexingComplete to false
> in .kde4/share/config/akonadi_nepomuk_feederrc.

unfortunately that doesn't work for me (using 4.9 RC1). Is there any way to easily check what has been indexed so far to see where the actual problem is?
Comment 143 Øystein Olsen 2012-07-06 10:14:14 UTC
(In reply to comment #142)
> (In reply to comment #138).
> > As a workaround, to reindex everything, set InitialIndexingComplete to false
> > in .kde4/share/config/akonadi_nepomuk_feederrc.
> 
> unfortunately that doesn't work for me (using 4.9 RC1). Is there any way to
> easily check what has been indexed so far to see where the actual problem is?

This does not work for me either, and it doesn't make much sense to me. The search widget in the address book application seems to work. I can type in th and only those names that contain th are listed, for example "Hjorth" and "Thomas" Although, sometimes one or two contacts are not filtered out.

To me it seems like the drop-down box/menu in kmail is broken. Sometimes it does show one name and leaves an empty space for the other names, other times it list all the names but the drop-down menu is too small. It shows only one name, but I can get to the other names with the up/down arrows. But most of the time, it shows nothing.
Comment 144 Joachim Wilke 2012-07-06 14:00:00 UTC
(In reply to comment #143)
> This does not work for me either, and it doesn't make much sense to me. The
> search widget in the address book application seems to work. I can type in
> th and only those names that contain th are listed, for example "Hjorth" and
> "Thomas" Although, sometimes one or two contacts are not filtered out.

Those are two completely different things regarding implementation.
Comment 145 Cédric Bellegarde 2012-07-30 14:48:09 UTC
https://bugs.kde.org/show_bug.cgi?id=304286

Here a patch fixing issue for people not using nepomuk.
Comment 146 Sérgio Basto 2012-07-30 19:14:18 UTC
(In reply to comment #145)
> https://bugs.kde.org/show_bug.cgi?id=304286
> 
> Here a patch fixing issue for people not using nepomuk.

now do a backport to kde 4.8 please, for we may test it.
Comment 147 Me 2012-08-04 21:17:23 UTC
I'd like to make a suggestion on this. Why not eliminate the conflict between the code that tracks 'recent addresses' and those saved in Contact folders. Instead, I suggest having a 'special' Contact folder (one that is persistent, like the Inbox) named recent-addresses. Just have Kontact/Kmail save 'new' email addresses to this folder. The user can choose to 'move' any addresses from this folder to their own Contacts folders, or delete them. Their choice. But this approach means that the code for auto-completion of email address can look at Contacts and only Contacts.
Comment 148 Eggert Ehmke 2012-08-04 21:25:15 UTC
With the recent update to KDE 4.9.00 (Gentoo) the problem is solved for me. All works fine, I even don't have to complete the names of my contacts. As soon as I type some letters of the name, all matching entries in the personal contacts are listed.
Comment 149 Andreas Pietzowski 2012-08-04 21:45:51 UTC
With my recent update to 4.9 it first didn't work. After I went to settings once and clicked on "configure completion order" it suddenly works now. Maybe there is still an update-bug which doesn't convert or corrects the settings?
Comment 150 Philipp Schmidt 2012-08-05 05:36:53 UTC
(In reply to comment #149)
I didn't need to change anything, with 4.9.0 it simply worked for me. Thanks to the devs for finally making this happen!
Comment 151 Richard Homonnai 2012-08-05 09:24:26 UTC
I am using Gentoo, it does still not work for me in 4.9.0 :(
Comment 152 Joachim Wilke 2012-08-05 12:33:00 UTC
Works for me with 4.9.0, all matching names are suggested after a few keystrokes. Thanks!!
Comment 153 Dimitrios Glentadakis 2012-08-05 12:41:56 UTC
Excuse me but i dont understand, 

1) There is a problem that affects almost all kmail users since 4.8.2 (for me)
2) No one from KDE said that has taken this bug to fix it or something that give the impression that KDE developpers care/know about
3) Suddenly, it works in 4.9, based on users replies

And there is no one who said that has fixed it in git.

I think that i participate in a bug report of Microsoft or Opera, leave the user alone keep him in the dark, he will understand when it is fixed by him self :D
Comment 154 Hrvoje Senjan 2012-08-05 15:03:35 UTC
With master, i was able to turn on nepomuk completion with editing
$KDEHOME/share/config/kpimcompletionorder
and adding
[General]
UseNepomuk=true

That works flawlessly!
Autocompletion using akonadi alone does not work for me.
Comment 155 Me 2012-08-05 15:29:10 UTC
The suggestion to edit:

~/.kde/share/config/kpimcompletionorder

and adding

[General]
UseNepomuk=true

has no effect for me. Auto-completion from Contacts Address Books still does not work.

Kubuntu 12.04, 64-bit, Kernel 3.2.0-27, KDE 4.9.00 (from Ubuntu ppa:kubuntu-ppa/backports repository), Kontact / Kmail version: 4.9

I said it before, and so have others, and I'll say it again. This is a 'basic' and 'fundamental' function of any email program. This MUST be fixed. It should be given a HIGH/CRITICAL importance rating, not because it causes Kontact/Kmail not to work, but because it is an EXPECTED feature by all who use Kontact/Kmail. This bug has been present to long.
Comment 156 Erwin Van de Velde 2012-08-05 16:37:35 UTC
I can confirm that this bug still exists in KDE 4.9. I did try the "UseNepomuk=true" fix, but to no avail. Come on devs, this is a rather basic feature and this bug has been here for far too long!
Comment 157 Hrvoje Senjan 2012-08-05 16:41:41 UTC
You won't get autocompletion on 4.9 with my 'solution'. This works only with master
Comment 158 Richard Homonnai 2012-08-05 17:02:24 UTC
Tried with all the "fixes" floating around, even rm-ing my nepomuk folder. Everything's unchanged.

What about the proposed patch? Is there anything that prohibits making this work without Nepomuk? Will try to make an ebuild für 4.9.0 about that...
Comment 159 Paul Sobey 2012-08-06 07:56:38 UTC
Hi there, 4.9.0 on gentoo here (akonadi 1.8.0). Still no fix. The bulk of my addresses are in an ldap direectory accessed over gssapi. I can pick addresses from this directory fine from the 'select recipient' dialogue, but the autocomplete only works for recent addresses.

I'd like to be able to debug a little here - could someone who knows more than me comment:

- are ldap addresses expected to auto-complete
- if so, where is the autocomplete list read from - akonadi or nepomuk (or both??)
- is there a way to view the addresses stored in this cache to confirm if they are there?
- is there a way to force flushing and re-population of this cache, short of the rather brute force 'delete all databases and settings' approaches that keep being mooted (and don't seem to work)

Thanks,
Paul
Comment 160 Jeroen van Meeuwen (Kolab Systems) 2012-08-06 08:04:34 UTC
(In reply to comment #159)
> I'd like to be able to debug a little here - could someone who knows more
> than me comment:
> 
> - are ldap addresses expected to auto-complete
> - if so, where is the autocomplete list read from - akonadi or nepomuk (or
> both??)
> - is there a way to view the addresses stored in this cache to confirm if
> they are there?

LDAP is supposed to be included in auto-complete, but since there's no locally cached version of the LDAP contents (AFAIK), it usually takes just that little longer.

IIRC, LDAP bind operations that may likely be required are to be configured separately - if these are not configured that may be the reason for the LDAP auto-completion not working in your GSSAPI scenario. Simple binds "WORK FOR ME" (though that doesn't help).
Comment 161 Paul Sobey 2012-08-06 08:12:47 UTC
The ldap source works fine in a standalone context - e.g. I can load kaddressbook and search through it, and select addresses from it within kmail. Seems to be just the auto-complete piece which isn't working. If someone can confirm where the addresses should be cached/stored I'll have a look on this machine and see if I can find them.

Btw +1 for the earlier 'recent addresses should be just another addressbook' comment - seems like a very sensible idea to me.
Comment 162 Michael S. 2012-08-06 21:13:02 UTC
I'm on kmail 4.9 with chakra-linux and autocompletion doesn't work with akonadi
addressbook.
Comment 163 Hrvoje Senjan 2012-08-06 21:59:06 UTC
Question for users that have this working with 4.9(final, not beta or RC). Do have working address completion via nepomuk or akonadi?
Comment 164 Me 2012-08-07 00:49:17 UTC
(In reply to comment #163)
> Question for users that have this working with 4.9(final, not beta or RC).
> Do have working address completion via nepomuk or akonadi?

Today, with the help of kubuntuforums.net member sumski, I got address autocompletion working on my Kubuntu 12.04, KDE 4.9.00, Kernel: 3.2.0-27-generic x86_64 (64 bit) system. He initially built a patched libkdepim4 package, but after further testing, he suggested that the patched version might actually not be needed. So, I reinstalled the 'official' libkdepim4 package and then made only the following changes:

Edit ~/.kde/share/config/akonadi_nepomuk_feederrc and change:

InitialIndexingComplete=true

to

InitialIndexingComplete=false

Additionally, ~/.kde/share/config/kpimcompletionorder was edited to add:

[General]
UseNepomuk=true

Perform a log out and then log in and allow nepomuk to finish indexing. After the indexing is finished, I launched Kontact and started a new email. Autocompletion works!
Comment 165 Eggert Ehmke 2012-08-07 07:02:48 UTC
Am Dienstag, 7. August 2012, 00:49:17 schrieben Sie:
> https://bugs.kde.org/show_bug.cgi?id=259949
> 
> --- Comment #164 from Paul Loughman <snowhog@mtaonline.net> ---

> Additionally, ~/.kde/share/config/kpimcompletionorder was edited to add:
> 
> [General]
> UseNepomuk=true
> 
> Perform a log out and then log in and allow nepomuk to finish indexing.
> After the indexing is finished, I launched Kontact and started a new email.
> Autocompletion works!

For me it works both:
UseNepomuk=true
brings me the autocompletion based on my content, 
UseNepomuk=false
brings me my contacts. Can't I have both? Ok, I guess the contacts are part of 
my content.
Comment 166 Hrvoje Senjan 2012-08-07 09:10:03 UTC
Eggbert, is this after you re-indexed your mails?
Comment 167 Paul Sobey 2012-08-07 10:53:24 UTC
I'm not sure if this is of use to anyone, but I just loaded up Akonadi Console, and confirmed that under my GSSAPI/LDAP resource, all the contacts I expect to see are in the store as mimetype text/directory in VCARD form. So Akonadi definitely has them, just that kmail can't/won't display them for some reason.
Comment 168 Hrvoje Senjan 2012-08-07 12:30:02 UTC
OK, i have tried with a new user with KDE trunk as of yesterday:
1) Added my IMAP (gmail account)

2) Restarted akonadi

3) Checked akonadi_nepomuk_feederrc, it had following content:
[InitialIndexing]
IndexCompatLevel=3
InitialIndexingComplete=true

4) I have changed this to false, and added
[akonadi_nepomuk_feeder]
DisableIdleDetection=true

5) Next, i restarted akonadi nepomuk feeder service with akonadiconsole, and waited until it finished

5a) While it was indexing, i then added (with akonadi google resource) my contacts on gmail account.

5b) Enabled kdebug output, opened kmail and started testing completion via akonadi -
It was working, but not 100%
Result when contact was found and displayed:
kmail2(21619)/libkdepim KPIM::AddresseeLineEdit::Private::akonadiPerformSearch: searching akonadi with: "zla"
kmail2(21619)/libkdepim KPIM::AddresseeLineEdit::Private::akonadiHandlePending: Pending items:  0
kmail2(21619)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 0 groups
kmail2(21619)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 1 contacts
kmail2(21619)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 0 groups
Note that the searches worked, but : if i searched with mail address, there where no results, if i then searched with name (same contact), result was displayed, and after contact was found, if i repeated search with mail address it was displayed (obviously, this all is true for contacts that have different name vs. mail address)

5c) Some contacts where found, but not shown:
kmail2(22845)/libkdepim KPIM::AddresseeLineEdit::Private::akonadiPerformSearch: searching akonadi with: "opensus"
kmail2(22845)/libkdepim KPIM::AddresseeLineEdit::Private::akonadiHandlePending: Pending items:  0
kmail2(22845)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 1 contacts
kmail2(22845)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 0 groups
That contact wasn't shown in completion list

5d) Contacts that had no name where not shown at all (see 5b)

6) Finally, nepomuk finished - restarted kmail, tried searches, same as with akonadi.

7) I then added 
UseNempomuk=True to kpimcompletionorder
restarted kmail
and searching was working with nepomuk, and it shown every contact!
Kdebugoutput:
kmail2(23610)/libkdepim KPIM::AddresseeLineEdit::Private::akonadiPerformSearch: searching akonadi with: "zsoko"
kmail2(23610)/libkdepim KPIM::AddresseeLineEdit::Private::akonadiHandlePending: Pending items:  0
kmail2(23610)/nepomuk (library) Nepomuk2::Query::QueryServiceClient::close:
kmail2(23610)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 0 contacts
kmail2(23610)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 0 groups
kmail2(23610)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 0 contacts
kmail2(23610)/libkdepim KPIM::AddresseeLineEdit::Private::slotAkonadiSearchResult: Found 0 groups

8) Commented out that UseNepomuk line, restarted kmail, and searching was again done via akonadi, with effects as described in 5 a), b), c) and d)
Comment 169 Michael S. 2012-08-07 12:59:44 UTC
(In reply to comment #165)
> 
> For me it works both:
> UseNepomuk=true
> brings me the autocompletion based on my content, 
> UseNepomuk=false
> brings me my contacts. Can't I have both? Ok, I guess the contacts are part
> of 
> my content.

Ok, this works for me too.
Comment 170 Sérgio Basto 2012-08-07 16:10:15 UTC
wtf you don't backport all fixes to 4.8.5 ?
Comment 171 Matěj Laitl 2012-08-07 16:14:27 UTC
(In reply to comment #170)
> wtf you don't backport all fixes to 4.8.5 ?

Sérgio, "wtf" is not really the right attitude towards volunteer coders working in their free time.
Comment 172 Sérgio Basto 2012-08-07 16:47:51 UTC
wtf you don't backport all fixes to 4.8.5 ? (In reply to comment #171)
> (In reply to comment #170)
> > wtf you don't backport all fixes to 4.8.5 ?
> 
> Sérgio, "wtf" is not really the right attitude towards volunteer coders
> working in their free time.

ok forget the "tf" :) 
So  
why you don't backport all fixes to 4.8.5 ?
to really test the fixes and not an all new version.
Comment 173 Kevin Kofler 2012-08-07 17:45:03 UTC
Because the 4.8.5 tarballs are already spun, and already built in most distros' build systems. Tarballs are respun only for critical fixes. (This one is not, sorry.) Even more so when the scheduled (public) release date is tomorrow.
Comment 174 Hrvoje Senjan 2012-08-07 17:49:41 UTC
It''s already released :)
http://dot.kde.org/2012/08/06/kde-ships-august-updates-plasma-workspaces-applications-and-platform

Also, completion with nepomuk is a new feature (at least to my understanding), so that's a no-go for < 4.9
Comment 175 Sérgio Basto 2012-08-07 17:54:16 UTC
(In reply to comment #173)
> Because the 4.8.5 tarballs are already spun, and already built in most
> distros' build systems. Tarballs are respun only for critical fixes. (This
> one is not, sorry.) Even more so when the scheduled (public) release date is
> tomorrow.

sorry I don't know about  4.8.5 , 
So why you don't backport all fixes to next minor release of 4.8 (4.8.6) ?
Comment 176 Kevin Kofler 2012-08-07 18:02:31 UTC
> It''s already released :)

Grrr, I wonder why we packagers bother reporting that their release doesn't build (the respun kde-l10n-da is still broken) if they release it anyway.

Though of course this means it's outright impossible to fix this bug in 4.8.5. :-)

> So why you don't backport all fixes to next minor release of 4.8 (4.8.6) ?

There will be no 4.8.6 release. Originally there wasn't even going to be a 4.8.5.
Comment 177 Paul Sobey 2012-08-08 10:35:12 UTC
The plot thickens slightly, I note that three addresses recently added to the directory _do_ show consistently in the address completion drop-down. As as test yesterday I added another user to the directory, and that _doesn't_ show after 24 hours, despite showing up in kaddressbook and being in the akonadi store as mentioned above. Is there a property on an akonadi contact record such that kmail will use it? I can't see any differences in how the records are presented in akonadiconsole.

Note that I'm aiming for akonadi-only drop down at the moment, not trying to add nepomuk searching into the mix as a few have suggested here.
Comment 178 Erwin Van de Velde 2012-08-08 14:15:49 UTC
I deleted everything of akonadi, nepomuk, kmail and addressbook and reconfigured it on KDE 4.9. At first it did not work, but now it magically works :-)
Nepomuk running without file indexer and in .kde4/share/config/akonadi_nepomuk_feederrc only this:

[akonadi_nepomuk_email_feeder]
Enabled=true

Do not ask why it works suddenly, but it made me happy :-)
Comment 179 Paul 2012-08-08 20:23:16 UTC
Another happy camper here :-)

Gentoo
KDE 4.9.0
app-office/akonadi-server: 1.8.0

I hev these settings in the config files that were mentioned:
$ cat akonadi_nepomuk_feederrc
[InitialIndexing]
IndexCompatLevel=3
InitialIndexingComplete=true

[akonadi_nepomuk_email_feeder]
Enabled=true

$ cat kpimcompletionorder 
[CompletionWeights]
140=99
145=100
172=98
173=100
178=99
341=99
346=98
355=100
513=98
514=99
519=100

[General]
UseNepomuk=true

I did start over with a new akonadi database (internal -> external MySQL) and I also deleted all Nepomuk data and let Nepomuk do a complete scan. I'm not 100% sure I had to do this, but it didn't hurt either.

I keep addresses in a kolab server. I'm using the kolabproxy akonadi plugin. The kolab server contains a folder with my own contacs as well as a folder with shared contacts.

When I start typing I get entries from:
- Recent addresses
- shared contacts
- "contacts found in my data"

I assume the last group contains Nepomuk search results, since it contains email addresses both from my personal contacts and from my complete email history: various work email addresses, addresses contained in forwarded mails, the lot.

If I type an address that exists only in my personal contacts, it shows up after 3-4 keystrokes.

All in all, it's quite powerful when it all works :-).

It would be interesting to figure out what the exact steps are that you need to do to get this to work. I'll try later with a different user on my machine. I have a few that haven't logged on since the KDE 4.9.0 upgrade. I'll get back if I learn anything worthwhile, but for now: YAY!
Comment 180 Hrvoje Senjan 2012-08-08 20:48:49 UTC
(In reply to comment #179)
> When I start typing I get entries from:
> - Recent addresses
> - shared contacts
> - "contacts found in my data"
> 
> I assume the last group contains Nepomuk search results,

Correct.
It's seems that a 'clean' nepomuk database, and/or UseNepomuk=true triggers completion with both nepomuk and akonadi. Before i cleaned db, and added UseNep.. = true, there was no completion with akonadi (on a database that dated before 4.9; on a clean setup, akonadi completion worked immediately). Once that was set up, and even after i removed UseNepomuk i still get my contacts with akonadi.
I have hit another bug in Nepomuk:
https://bugs.kde.org/show_bug.cgi?id=304804
With that, there was no completion with nepomuk, but also with akonadi!
As stated in # 304804, reverting that commit brought back completion with both methods.
Comment 181 Paul Sobey 2012-08-09 09:26:05 UTC
> Gentoo
> KDE 4.9.0
> app-office/akonadi-server: 1.8.0

Same here

> I did start over with a new akonadi database (internal -> external MySQL) and I
> also deleted all Nepomuk data and let Nepomuk do a complete scan. I'm not 100%
> sure I had to do this, but it didn't hurt either.
>
> I keep addresses in a kolab server. I'm using the kolabproxy akonadi plugin.
> The kolab server contains a folder with my own contacs as well as a folder with
> shared contacts.
>
> When I start typing I get entries from:
> - Recent addresses
> - shared contacts
> - "contacts found in my data"
>
> I assume the last group contains Nepomuk search results, since it contains
> email addresses both from my personal contacts and from my complete email
> history: various work email addresses, addresses contained in forwarded mails,
> the lot.
>
> If I type an address that exists only in my personal contacts, it shows up
> after 3-4 keystrokes.
>
> All in all, it's quite powerful when it all works :-).

Encouraged by the above I tried:

- remove .kde4/share/config/*akonadi* and *nepo*
- remove .kde4/share/apps/nepo*
- drop akonadi database and recreate (external mysql)

Same result as before - no auto-completion, addresses are definitely in 
the (new) akonadi DB.

Are any kmail/akonadi devs on this bug? Feels like a lot of people 
fumbling around in the dark trying various things without any real steer 
as to what might help. The completion works for some, not others, 
for some blatting some parts of the config works, and for others it 
doesn't.

The tech on offer here is clearly superb when it works well, the issue 
seems to be that it's a little fragile, and old/incomplete config or old 
database schemas are biting people perhaps. If someone who knows how it 
all works could assist some of the people on the bug to troubleshoot, 
perhaps we could figure out more where the problem lies.

I don't want to come across as yet another whingeing client of free open 
source software, everyone here clearly works very hard, just want to get a 
good result for all.

Cheers,
Paul
Comment 182 Till Adam 2012-08-09 10:25:29 UTC
Thanks Paul, and all the others who have tried to help us systematically debug and improve the situation. I'm one of the people who worked on the fixes for 4.9 and obviously stuff works for me (TM). Part of the problem is that there are various people trying various combinations of versions of the stack and various configuration settings with varying results, so it's quite hard to get a decent idea of what works or doesn't for whom and thus do concrete steps to improve. Let me at least try to describe what should work, in 4.9, as a baseline:

- recent addresses should be completed, unless disabled in the config, this is currently completely independent from both Akonadi and nepomuk
- search in addressbooks should work, this goes through akonadi's search interface which asks nepomuk for hits in things it has indexed via the akonadi feeders into nepomuk ("finds anything known to akonadi, and if the feeders are on, thereby nepomuk"). If you have no feeders, this finds nothing. If you have no nepomuk, this also finds nothing.
- unless disabled (which is the default in 4.9 because David found performance issues with this feature which are being worked on), there should be an additional search triggered which goes directly to nepomuk, not via akonadi. This yields the "Contacts found in your data" results and searches any and all email addresses known in the system. If you have not nepomuk, this finds nothing, but the akonadi feeders are not needed, since nepomuk finds emails from all sorts of places, including the file system, if that is enabled globally in nepomuk.

Additionally there are some constraints which filter these results, sometimes causing the impression that results are missing or not found. For example we only search from 3 letters or more in akonadi and nepomuk, otherwise we'd get thousands of hits, in nepomuk, which is way too slow. So if you type only 2 letters, only recents are searched. Also, we filter contacts that have no valid email address, this being email completion, they would be useless and so on. There are some additional sanity checks, which might have bugs, and could thus cause individual things not to be found that you think should be there. The debug output should help finding such patterns and if we can reproduce and understand them, we'll be happy to fix them.

Hopefully this helps some of you to narrow down the problem a bit more, so we can action it.

As a meta-comment: these are very interesting times in the Qt world. We all have jobs that to some extent are impacted by the recent tectonics around Nokia and all our efforts are focused on making sure Qt5 happens, rocks, continues to thrive and our companies and jobs as an extension of that. There's a group of very dedicated people who is trying to maintain a bit of progress in kdepim, in their extremely limited spare time, and many of them have been doing so for almost 10 years. Cut us some slack, ok? And thanks again for all of you who are helping and being constructive. We love you.
Comment 183 Paul Sobey 2012-08-10 09:04:16 UTC
> --- Comment #182 from Till Adam <adam@kde.org> ---
> Thanks Paul, and all the others who have tried to help us systematically debug
> and improve the situation. I'm one of the people who worked on the fixes for
> 4.9 and obviously stuff works for me (TM). Part of the problem is that there
> are various people trying various combinations of versions of the stack and
> various configuration settings with varying results, so it's quite hard to get
> a decent idea of what works or doesn't for whom and thus do concrete steps to
> improve. Let me at least try to describe what should work, in 4.9, as a
> baseline:
>
> - recent addresses should be completed, unless disabled in the config, this is
> currently completely independent from both Akonadi and nepomuk
> - search in addressbooks should work, this goes through akonadi's search
> interface which asks nepomuk for hits in things it has indexed via the akonadi
> feeders into nepomuk ("finds anything known to akonadi, and if the feeders are
> on, thereby nepomuk"). If you have no feeders, this finds nothing. If you have
> no nepomuk, this also finds nothing.
> - unless disabled (which is the default in 4.9 because David found performance
> issues with this feature which are being worked on), there should be an
> additional search triggered which goes directly to nepomuk, not via akonadi.
> This yields the "Contacts found in your data" results and searches any and all
> email addresses known in the system. If you have not nepomuk, this finds
> nothing, but the akonadi feeders are not needed, since nepomuk finds emails
> from all sorts of places, including the file system, if that is enabled
> globally in nepomuk.

Thankyou for such a comprehensive response!

With the above in mind, I have some questions:

- search in addressbooks goes kmail -> akonadi -> nepomuk for even 
akonadi-only data? That implies that our search scope for addressbook 
lookup debug covers both of those two technologies

- I have nepomuk file based indexing disabled (but email indexing switched 
on) - could that affect this?

- I was particularly confused that a small subset of my addresses worked 
in an addressbook search recently, despite the fact that they looked 
identical in the akonadi store - does this help point the finger? 
Interestingly, after I cleaned out both akonadi and nepomuk data 
yesterday, I now have no addresses working for the lookup, which at least 
is more consistent behaviour

- how would you recommend that non-developer (but technical) users could 
help you debug this? I'm a networks/linux sysadmin running gentoo, just no 
C++ experience - will follow instructions if you need, although with the 
caveat that this is my work machine and I can't use terribly invasive 
techniques on this machine (e.g. build new kde from trunk)
Comment 184 Ralph Moenchmeyer 2012-08-10 13:36:22 UTC
I upgraded yesterday from KDE 4.8.4 to KDE 4.9 under Opensuse 12.1 (x86_64). After that address completion did not (!) at all work for existing users - just as before . 

However, it did work for new users which I set up for tests after the KDE 4.9 upgrade. And for the new users address completion worked as described in comment #182 by Till Adam. 

So, it seems that one has to configure akonadi + the kdepim programs including kaddressbook from scratch to get the address completion and the akonadi indexing of mail addresses to work for users that previously already used some KDE 4.8 version.

I did this in a quite radical way by deleting configuration/data files and directories related to Akonadi and the kdepim programs I use.  It was not dangerous to do so in my case as all my mails, calendar data and addresses reside on an Imap, an LDAP and on an Open-Xchange server and not in some local files. Otherwise, one probably would have to be more careful.

On the other side, as akonadi/kdepim information and data are distributed and scattered over several configuration directories, one has to be careful not to omit some configuration data.   
Actually, only after some hours of trial and errors I found that a thorough cleansing in "~/.kde4" and "~/.local" was essential to get everything working and all mails/contacts reindexed as expected. 

I did the following steps : 
1) I stopped the akonadi service and all kdepim applications. 
2) I kept all nepomuk (sub)services (including the mail indexer) activated under KDE's "systemsettings". 
3) I deleted the directory "akonadi" under ~/.config
4) I deleted all files and directories related to akonadi, nepomuk  and kdepim programs in "~/.kde4/share/apps" and "~/.kde4/shared/config". 
5) I deleted the directory "~/.local/share/akonadi" (i.e. I deleted the mysql database for akonadi) and "~/.local/share/contacts.
6) To be on the save side: I deinstalled an reinstalled the akonadi and the kdepim RPM packages for KDE 4.9  
7) Logout, init 3 and init 5    
8) Start of Kontact - reconfiguration of the standard identity, setup of my connection to my IMAP servers, setup of my connections to the Open-Xchange 6 server and to my LDAP-server for different addressbooks and calendars. 
9) I then let akonadi and nepomuk do and finish (!) their indexing work (watch the CPU load of the "virtuoso-t" process!).  In my case that took over two hours due to a large amount  of mails on the IMAP server. (The file indexer (strigi) was restricted to do its work only on some selected directories and ended its job rather quickly.)  

After that I restarted KDE + Kontact again and address completion now gives me some reasonable information from the different addressbooks connected. 

At least as long as the starting letter sequence corresponds to the beginning of a name or the beginning of a mail address. ( A "clark" in "john-clark" e.g. is not recognized).
A strange thing is also that quite new addresses, which I registered during a kontact session in some local and remote addressbooks, only were found after a restart of the akonadi service  and a restart of kontact. This is a bit annoying. 

However, I am happy to get at least address suggestions from different regular addressbook resources now and not only suggestions from the stock of recently used addresses.
Comment 185 Hannes Kuhnert 2012-08-10 18:13:12 UTC
(In reply to comment #184)
> I upgraded yesterday from KDE 4.8.4 to KDE 4.9 under Opensuse 12.1 (x86_64).
> After that address completion did not (!) at all work for existing users -
> just as before . 

> So, it seems that one has to configure akonadi + the kdepim programs
> including kaddressbook from scratch to get the address completion and the
> akonadi indexing of mail addresses to work for users that previously already
> used some KDE 4.8 version.

Not necessarily. I can’t judge if there has been an alternative to deleting “everything” on your system, but at least in my case it was enough to edit akonadi_nepomuk_feederrc. It looks like that now:

| [InitialIndexing]
| IndexCompatLevel=3
| InitialIndexingComplete=true
|
| [akonadi_nepomuk_email_feeder]
| Enabled=true
|
| [akonadi_nepomuk_feeder]
| DisableIdleDetection=true

Now I’ve got auto-completion as soon as I type in one character—which is great—, but it only matches beginnings of words. That works on names and parts of addresses. I can e. g. type in “gmx.de” and will get all addresses on that domain. But if I type in “tu-chemnitz.de” it won’t bring up addresses at “hrz.tu-chemnitz.de”. And not always all on that basis expected addresses are shown: I’m having two almost identical contacts—one is shown in KMails autocompletion, the other one never. If I knew how to check Nepomuks index …
Comment 186 Eggert Ehmke 2012-08-10 19:44:55 UTC
Am Freitag, 10. August 2012, 18:13:12 schrieben Sie:

> Not necessarily. I can’t judge if there has been an alternative to deleting
> “everything” on your system, but at least in my case it was enough to edit
> 
> akonadi_nepomuk_feederrc. It looks like that now:
> | [InitialIndexing]
> | IndexCompatLevel=3
> | InitialIndexingComplete=true
> | 
> | [akonadi_nepomuk_email_feeder]
> | Enabled=true
> | 
> | [akonadi_nepomuk_feeder]
> | DisableIdleDetection=true

Should not there be some configuration options so users don't have to edit 
files that they might not know about?
Comment 187 Hannes Kuhnert 2012-08-10 20:09:57 UTC
(In reply to comment #186)
> Should not there be some configuration options so users don't have to edit 
> files that they might not know about?

I think 
| [akonadi_nepomuk_email_feeder]
| Enabled=true
can be found in the settings dialog for the desktop search (“enable e-mail indexing”).

IIRC the only thing I did was changing
| InitialIndexingComplete=true
to false. That’s something that should not need to be settable via the GUI.
Comment 188 Anders Lund 2012-08-11 08:32:41 UTC
(In reply to comment #184)
> I upgraded yesterday from KDE 4.8.4 to KDE 4.9 under Opensuse 12.1 (x86_64).
> After that address completion did not (!) at all work for existing users -
> just as before . 
> 
> However, it did work for new users which I set up for tests after the KDE
> 4.9 upgrade. And for the new users address completion worked as described in
> comment #182 by Till Adam. 
> 
> So, it seems that one has to configure akonadi + the kdepim programs
> including kaddressbook from scratch to get the address completion and the
> akonadi indexing of mail addresses to work for users that previously already
> used some KDE 4.8 version.

It would be nice if someone can come up with a list of the minium of required destruction.

Please say that deleting nepomuk data is not required - not all of it is autogenerated!

Please say that deleting all ones akonadi resources is not required, it takes time and effort to set it up properly!
Comment 189 Hannes Kuhnert 2012-08-11 08:44:29 UTC
(In reply to comment #188)
> It would be nice if someone can come up with a list of the minium of
> required destruction.

You may want to read <a href="http://bugs.kde.org/show_bug.cgi?id=259949#c138">comment #138</a>.
Comment 190 Anders Lund 2012-08-11 09:22:17 UTC
(In reply to comment #189)
> (In reply to comment #188)
> > It would be nice if someone can come up with a list of the minium of
> > required destruction.
> 
> You may want to read <a
> href="http://bugs.kde.org/show_bug.cgi?id=259949#c138">comment #138</a>.

I had already tried that, and restarted akonadi, with no change. Now I restarted my KDE session, but I believe what made the trick for me was editing kpimcompletionorderrc, adding a General section with UseNepomuk=true.

But it is working, which is wonderful, one more step on the road to kmail being in a working state <3
Comment 191 Ralph Moenchmeyer 2012-08-13 09:12:36 UTC
(In reply to comment #185,  to comment #187 and comment #190 )

In answer to  comment #185 and comment #187: 
> IIRC the only thing I did was changing
> | InitialIndexingComplete=true
> to false. That’s something that should not need to be settable via the GUI.

Regarding: Setting "InitialIndexingComplete=true" to false: 
Maybe that would have been enough to start a reindexing. Unfortunately, I have no chance to test that again on my system. I had tried that before with KDE 4.8.4 without any success - maybe it would have worked with KDE 4.9 now. It is worth trying. 

I also agree that deleting "everything" regarding akonadi, nepomuk and kontact as described in comment #184 is a quite radical method, which may not be applicable for everyone. However, it worked at least, and it shows in addition that a clean install of KDE 4.9 leads to success. 

Regarding comment #190 and the following aspect: 
> but I believe what made the trick for me was editing kpimcompletionorderrc, 
> adding a General section with UseNepomuk=true.

My present "kpimcompletionorderrc" (which was generated freshly by the system in course of what I described in #184) does not (!) contain a line "UseNepomuk=true". Interestingly enough, addresscompletion under KDE 4.9 works nevertheless for me. Can somebody explain this, please ?
Comment 192 Paul van Erk 2012-08-13 09:21:27 UTC
I'm not sure anyone can explain what is going on with this one. ;)
Meanwhile, I do have it working, but I'm not sure how it happened. I'm using Google contacts (akonadi resource) and autocompletion seems to be working consistently now. I had that working earlier, but then it stopped when I unchecked the use of recent addresses and it didn't work anymore after enabling it again. I'm afraid to try it again, since it's all so fragile. But it is another type of resource that is now working. I too, don't have the "UseNepomuk=true". When I had added that, it gave me so much rubbish in my address bar, it was unusable. This is openSUSE 12.1 with KDE 4.9, by the way.
Comment 193 Anders Lund 2012-08-13 09:34:50 UTC
I have got things working, after editing config files and restarting akonadi and kde. The UseNepomuk thing in kpimcompletionorder have gone again, so now I have completion form my addressbook + recent addresses (that is fine, the other option came with A LOT of undesirable addresses but also a few useful ones...)

Nice to have it working!
Comment 194 Mathias Homann 2012-08-13 10:09:18 UTC
I, on the other hand, do not have a  "kpimcompletionorderrc" file. KDE 4.9.0 on openSUSE 12.1 here, and autocompletion still only uses recently used emails, but not addressbook sources.

my only addressbook source is a webdav / owncloud source.
Comment 195 Anders Lund 2012-08-13 10:36:39 UTC
I also store my addressbooks in owncloud. AFAICT, setting InitialIndexingComplete to "false" in akonadi_nepomuk_feederrc and then restarting the pc (because restarting nepomuk is difficult and restarting KDE does not always do that) is what is required.

The "UseNepomuk" think I believe leads to a myriad of addresses "found in your data", but in my case that setting does not appear to stick.
Comment 196 Paul Sobey 2012-08-13 11:22:39 UTC
When I cleaned out my akonadi/nepomuk stores before, I didn't touch the ~.config/akonadi directory. After reading several of these posts I just had another total cleanout of akonadi/nepomuk data, and this time included that dir.

When redefining services, I noticed that in my akonadi configuration I no longer had the option to choose an ldap address book. After inspecting kaddressbook, I noticed a global option to define an ldap source. I did that, and now ldap completion (and nepomuk 'addresses dredged from emails') all works flawlessly.

Noting it here in case anyone faces the same issue - has the way in which akonadi ldap address sources deliberately changed?

Happy it's working for now!
Comment 197 Paul van Erk 2012-08-14 09:06:09 UTC
Okay, scratch that. It's the next day and it stopped working. Only getting recent addresses again. I did nothing else but close kmail, shutdown the computer, sleep, wake up, turn it on and start kmail. :(
(posting this to show how unstable it is, even if you think you finally have it working)
Comment 198 Anders Lund 2012-08-15 08:37:38 UTC
Created attachment 73175 [details]
Display the unstability of this broken feature

The autocompletion is NOT stable. Today, entering "an" in the to field gives 3 completions, while in the selection dialog there are over 30.

I just restarted KDE, so everything wrt nepomuk running should be dandy!

:-(((
Comment 199 Anders Lund 2012-08-15 08:53:42 UTC
I think the only sane descision is to drop the nepomuk path, or at least provide an alternative, while nepomuk is reaching a functional state.
Comment 200 Ralph Moenchmeyer 2012-08-17 09:11:16 UTC
(In reply to comment #198)
> Created attachment 73175 [details]
> Display the unstability of this broken feature
> 
> The autocompletion is NOT stable. Today, entering "an" in the to field gives
> 3 completions, while in the selection dialog there are over 30.

I tested also a little bit regarding completeness of the autocompletion suggestions. 

I cannot really confirm what Anders Lund wrote in his latest comment. This is because the filter and search functionalities obviously work differently for the selection dialog than for autocompletion. The two searches work according to different criteria. 

Regarding Anders' example with "an" or even "and", I, too, get a lot less hits in kmail's address autocompletion than with the same search in the address selection box or with a direct search in kaddressbook. (My adressbook is that of an OX 6 server.) 

However, the difference in my case is basically due to the fact that the standard search in kaddressbook also delivers results where the search expression is just a part of the text strings of several of the different fields comprised in the address record. With "and" as a search expression in the addressbook and the selection field I also get all addresses where I filled out the country field with "Deutschland".       

One can really ask: Would you expect this variety of hits in the address autocompletion ? 

As far as I can see the addresscompletion in its present state finds addresses where distinguished name fields of the address record start (!!) with the search expression or where certain distinguished parts of the email address start with the search expression. And regarding such a kind of search the result list seems to be complete in my case.   

So the big differences in the search result sets Anders describes may be due to the fact that indexing and searching is differently implemented for autocompletion than for for the selection field. 
So, could somebody of the developers describe in more detail how the search functionality in autocompletion works and what criteria it exactly takes into account?
Comment 201 Me 2012-08-17 20:49:50 UTC
(In reply to comment #147)
> I'd like to make a suggestion on this. Why not eliminate the conflict
> between the code that tracks 'recent addresses' and those saved in Contact
> folders. Instead, I suggest having a 'special' Contact folder (one that is
> persistent, like the Inbox) named recent-addresses. Just have Kontact/Kmail
> save 'new' email addresses to this folder. The user can choose to 'move' any
> addresses from this folder to their own Contacts folders, or delete them.
> Their choice. But this approach means that the code for auto-completion of
> email address can look at Contacts and only Contacts.

I'm replying to my own suggestion. Focus on keeping email address autocompletion confined to Kontact/Kmail only. It would be a very simple fix to have a persistent special folder -- recent-addresses -- as a sub-folder under Personal Contacts, and place all email recipient address "not already in user created folders under Personal Contacts" there. Change the behavior of email address autocompletion to look "only" in Personal Contact folders.
Comment 202 quazgar 2012-08-21 06:09:28 UTC
To be more specific about the sporadic "works now" messages: For me, it started to partly work after upgrading akonadi-server from 1.7.2 to 1.8.0, while keeping KDE (and Kontact) still at 4.8.3.

"Partly" because:
- It does not work right after startup, but seems to need some time (build up the database?).
- In the beginning only "newer" addresses were completed.
- Names are completed from typing the first letter (not first 3 letters), but (sometimes) only after the whole first name part has been typed once. Example: I'm looking for the address of John Doe.
  * "J" -> no result
  * "Jo" -> no result
  * "Joh" -> no result
  * "John" -> finds address
  * "J" -> finds address
Comment 203 quazgar 2012-08-21 06:12:03 UTC
And one comment to the developers: If there is anything we can try in the akonadi console, e.g. custom search queries, we could certainly do that to help pinning down any remaining problems.
Comment 204 quazgar 2012-08-21 06:26:22 UTC
OK, looking at the akonadiconsole debugging output, for each entry, two search queries seem to be started, the first one being successful, the second one not. I'm looking for the email address of my good friend "Foo Testuser <testuser@example.com>" here and have just entered "Foo" in KMail:

357 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?r WHERE { graph ?g { ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?r a nco:PersonContact . { ?r nco:fullname ?v . ?v bif:contains \"'Foo'\" . } UNION { ?r nco:nameGiven ?v . ?v bif:contains \"'Foo'\" . } UNION { ?r nco:nameFamily ?v . ?v bif:contains \"'Foo'\" . } UNION { ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . ?v bif:contains \"'Foo'\" . } } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
* 84255 SEARCH (UID 84255 REV 1 REMOTEID "Hvi9oupQLo.vcf" MIMETYPE "text/directory" COLLECTIONID 507 SIZE 119 DATETIME "19-Aug-2012 11:54:31 +0000" FLAGS () ANCESTORS ((507 "/home/daniel/.local/share/contacts/")) PLD:RFC822 {119} BEGIN:VCARD EMAIL:testuser@example.com FN:Foo Testuser N:Testuser;Foo;;; UID:Hvi9oupQLo VERSION:3.0 END:VCARD ) 
357 OK SEARCH completed
358 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'Foo*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
358 OK SEARCH completed

As can be seen, query 357 was successful, while 358 did not return any results.
Comment 205 Anders Lund 2012-08-21 07:32:09 UTC
For me, address completion worked 1 or two days after editing the akonadi_nepomuk_feederrc file, and then stopped again.

Nepomuk is running fine, and normal searc using nepomuk in dolphin or krunner is fine, so I assume this is not the fault of nepomuk.
Comment 206 Hannes Kuhnert 2012-08-21 09:10:14 UTC
(In reply to comment #204)
> OK, looking at the akonadiconsole debugging output, for each entry, two
> search queries seem to be started, the first one being successful, the
> second one not. I'm looking for the email address of my good friend "Foo
> Testuser <testuser@example.com>" here and have just entered "Foo" in KMail:
> […]
> As can be seen, query 357 was successful, while 358 did not return any
> results.

As far as I can see query 357 was a query for single contacts, whereas query 358 seems to have been one for contact groups.
Comment 207 Anders Lund 2012-08-22 08:13:00 UTC
After a reboot, logically including a restart of KDE, I have NO autocompletion of my addressbooks, and most of my "recent addresses" were lost. My address books are present and functional, available in the completion order setting in kmail. Nepomuk search works using krunner or dolphin. Using krunner, I can initiate a new mail to some of my contacts, but not groups (stored locally, since the owncloud addressbook appears to be unusable for those).

akonadi_nepomuk_contact_feederrc looks like this:
[InitialIndexing]
IndexCompatLevel=1
.kde4/share/config/akonadi_nepomuk_contact_feederrc (END)

akonadi_nepomuk_feederrc looks like this:
[InitialIndexing]
IndexCompatLevel=3
InitialIndexingComplete=false

[akonadi_nepomuk_email_feeder]
Enabled=false

[akonadi_nepomuk_feeder]
DisableIdleDetection=true

---
Are those allright?
Is there a way I can tell it to work?
Is there any data I can collect to help resolving this misery?
Comment 208 Andreas Pietzowski 2012-09-16 12:37:01 UTC
It is again broken in KDE 4.9.1. No autocompletion in KMail composer window. I can't believe that this is so a hard task to get this basic feature working. How do the developers send emails? Maybe you don't use KDEs mail client, do you? Or maybe you have all email addresses in your mind and type them everytime... ;-)

Pleeeaze fix that. Thanks.
Comment 209 Michael S. 2012-09-16 13:13:06 UTC
(In reply to comment #208)
> It is again broken in KDE 4.9.1. No autocompletion in KMail composer window.
> I can't believe that this is so a hard task to get this basic feature
> working. How do the developers send emails? Maybe you don't use KDEs mail
> client, do you? Or maybe you have all email addresses in your mind and type
> them everytime... ;-)
> 
> Pleeeaze fix that. Thanks.

I'm on KDE 4.9.1 and autocompletion still works.
Comment 210 wuselwu 2012-09-16 13:19:14 UTC
I've been using openSUSE with KDE 4.x for a long time, currently 4.9.1, and autocompletion has never ever worked correctly for me on any single KDE release. I just have given up on this. A shame for KDE.
Comment 211 Andreas Pietzowski 2012-09-16 15:30:54 UTC
Even if it works for some guys that doesn't mean that this bug is fixed. Seems like many people have a big problem with auto completion.

Hint: KRunner can search all addresses from akonadi successfully if you enable "Contacts" in it's settings. Maybe KMail should just copy the auto-completion code from KRunner to get it working somehow? ;-)
Comment 212 Anders Lund 2012-09-16 16:56:20 UTC
I have reenabled email indexing, and now autocompletion appears to work.
I do not understand why autocompletion depends on email indexing being enabled - that must be a bug/error.

I dislike having indexing completed, it uses WAY too much CPU - for example, marking a mail as read means > 25% CPU used by virtuoso-t for > 4 seconds. That can not be nessecary, please. Email indexing also is not disabled when on battery, drastically lowering the battery time with that CPU abuse pattern. That is of course a different problem, but please remove that dependency!
Comment 213 Ingo Ratsdorf 2012-09-16 20:50:13 UTC
Unfortunatelt have to agree with Larx, it never, ever worked for me in any version either.
Currently on 4.9. Email indexing is a no-go for me, I don't have the CPU power and I have IMAP accounts on my own server with years of emails. And since I do not search years of emails, only by subjects (which works fine).
So if I can search years of emails in real-time, why can't I search an address book for an address?
Comment 214 Henning Becker 2012-09-16 21:02:54 UTC
(In reply to comment #208)
> It is again broken in KDE 4.9.1. No autocompletion in KMail composer window.
> I can't believe that this is so a hard task to get this basic feature
> working. How do the developers send emails? Maybe you don't use KDEs mail
> client, do you? Or maybe you have all email addresses in your mind and type
> them everytime... ;-)
> 
> Pleeeaze fix that. Thanks.

Try to reenable initial indexing in ~/.kde4/share/config/akonadi_nepomuk_feederrc:
"InitialIndexingComplete=false"
and restart Akonadi: # akonadictl restart

This worked for me with 4.9.1!

Regards,
Henning
Comment 215 wuselwu 2012-09-17 04:09:33 UTC
Can't it be done to have a simple, but basic feature like "email autocompletion" working out-of-the-box, without fiddling around with Akonadi internals? (I've had my share of that when trying to get Akonadi to work when it first became necessary for running Kmail.)
OT: I still fail to see the advantages I have when using Akonadi. Up to now I only have an enormous amount of additional, error-prone overhead infrastructure, but not more functionality than the old KDE addressbook or Thunderbird.
Comment 216 Cédric Bellegarde 2012-09-17 07:16:05 UTC
(In reply to comment #215)
> Can't it be done to have a simple, but basic feature like "email
> autocompletion" working out-of-the-box

In KDE 4.10, Akonadi completion is working out of the box when nepomuk is disabled:
https://bugs.kde.org/show_bug.cgi?id=304286
Comment 217 Ralph Moenchmeyer 2012-09-17 07:58:25 UTC
> Try to reenable initial indexing in
> ~/.kde4/share/config/akonadi_nepomuk_feederrc:
> "InitialIndexingComplete=false"
> and restart Akonadi: # akonadictl restart

For me autocompletion works in 4.9.1 - but I had to do the reindexing, too, when upgrading from 4.9.0. 
However, I know at least 2 people who unfortunately have given up to use kontact/kmail completely due to this and other problems. Dear developers, you probably cannot expect normal users to know that the parameter "InitialIndexingComplete" exists, where it is located and that after an KDE upgrade they may have to reset it to "false".
Comment 218 Sérgio Basto 2012-09-25 02:56:19 UTC
(In reply to comment #217)
> > Try to reenable initial indexing in
> > ~/.kde4/share/config/akonadi_nepomuk_feederrc:
> > "InitialIndexingComplete=false"
> > and restart Akonadi: # akonadictl restart
> 
> For me autocompletion start works in 4.9.1 - but I had to do the reindexing, too,
> when upgrading from 4.9.0. 
> However, I know at least 2 people who unfortunately have given up to use
> kontact/kmail completely due to this and other problems. Dear developers,
> you probably cannot expect normal users to know that the parameter
> "InitialIndexingComplete" exists, where it is located and that after an KDE
> upgrade they may have to reset it to "false".

Start working here !  with 4.9.1 Fedora 17 update, 
Hallelujah  :)
Comment 219 wuselwu 2012-09-25 03:00:52 UTC
On openSUSE 12.2 with extra KDE 4.9 repo too. Miracles happen!
Comment 220 Murz 2012-09-25 05:00:36 UTC
On KDE 4.9.1 autocomplete works normally for ascii symbols, but for unicode (cyrillic for example) - not so good. When I type "Alexey" - it do full search and return results, but when I type "Алексей", it show in results only contacts, that was loaded for previous results (so with Alexey + Алексей words) without do additional query for search new results. System is Kubuntu 12.04. Anybody else can reproduce this problem?
Comment 221 GK 2012-09-25 05:07:42 UTC
I can reproduce the same issue as mentioned in comment 220 above.  When I type 'Йонка', nothing appears, compared with 'Yonka' which is the same in Latin letters. If I go to the "Select" button, the Cyrillic name is shown there. Otherwise the autocompletion works fine
Running Kubuntu 12.04.1 with all updates of 4.9.1.
Comment 222 Anders Lund 2012-09-25 06:54:54 UTC
For me, it goes up and down. Sometimes it works, sometimes not. Today it does not. Nepomuk is running and well, I can find my contacts using krunner, but kmail composer? No. I believe it will take a reboot or relogin to get it back.
Comment 223 quazgar 2012-09-25 17:16:43 UTC
(In reply to comment #220)
> When I type "Alexey" - it do full
> search and return results, but when I type "Алексей", it show in results
> only contacts, that was loaded for previous results (so with Alexey +
> Алексей words) without do additional query for search new results.

Hi, this sounds like a different bug. Please open a new bug report or check if it exists already and add your comment there. It's best to keep this bug report as clean as possible...

Thanks!
Comment 224 Alvise 2012-09-26 17:39:06 UTC
In my case (kde4.9.1 with opensuse12.2), autocompletion is having a strange behaviour.

First, it did not work at all. Then it started to work after changing the order in settings/composer/general/configure completion order

Now, it fails to find a name on the first try, but if I do the following I manage to get results. Let's suppose that I am looking for all the names with "Adrian". I write "a" (nothing happens), then "d" , then "r" (here I start to have some names that match a previous autocompletion search), then I put a space (here empty results), then I delete the space character and tadaa, voilà, I get all the names that include "adr".
Comment 225 Ingo Ratsdorf 2012-09-27 11:10:48 UTC
What are you guys doing so that autocompletion works? It does not work for me at all, using KDE Ubuntu binaries 4.9.1.
Autocompletion by dropdown, corect addressbook order, krunner can find contacts...
....just not KMail or KOrganiser.

What's wrong?

I have nepomuk semantic desktop enabled, however file and email indexing disabled since I definitely do not need it or want it on the laptop.
Comment 226 Sérgio Basto 2012-09-27 19:58:47 UTC
(In reply to comment #225)
> What are you guys doing so that autocompletion works? It does not work for
> me at all, using KDE Ubuntu binaries 4.9.1.
> Autocompletion by dropdown, corect addressbook order, krunner can find
> contacts...
> ....just not KMail or KOrganiser.
> 
> What's wrong?
> 
> I have nepomuk semantic desktop enabled, however file and email indexing
> disabled since I definitely do not need it or want it on the laptop.

you have to shake the machine :) 

 Try to reenable initial indexing in
 ~/.kde4/share/config/akonadi_nepomuk_feederrc:
 "InitialIndexingComplete=false"
 and restart Akonadi: # akonadictl restart
 
 This worked for me with 4.9.1!

I just disable Nepomuk file indexer
Comment 227 regi.hops 2012-10-03 13:56:40 UTC
Another try with KDE 4.9.2.
In 4.9.1 the mentioned work-around "InitialIndexingComplete=false" give me most (not all) contacts in the address search.
In 4.9.2 I tried the same work-around again, and again the address search doesn't find all addresses.
So nothing changed for me, the address search is still unreliable.
And changes in the address book are not reflected directly in the search result of KMail2, you need to restart Kontact or KMail2 to see the changes (but may be this is another bug).

Wouldn't it be possible to use the search bar from the Addressbook itself, or just the algorithms behind?
This works reliable, I could even search for other things like city, telephone and so on.
OK - It would also find contacts without an email address, but they could be marked or grayed-out in the result list.
Comment 228 Ingo Ratsdorf 2012-10-03 20:18:00 UTC
I can confirm that in KDE 4.9.1 (Ubuntu binaries),  "InitialIndexingComplete=false" does not do anything for me. Maybe because all my contacts come via CardDAV?
I agree with regi.hops@gmx.net: Why can't we use the already established working code from KAddressbook? If it returns contacts without email address, well - too bad, then I should not search for that contact or it would be a good reminder to get one for this contact... ;-)
Comment 229 Anders Lund 2012-10-03 20:26:32 UTC
Yay, something that actually works exist, so use that while the other thingy is developed. The working implementation is not long away - click the "..." button at the end of the address field. 

Today, kmail completes some (a few) matches from my addressbooks typing in the address fields. The elipsis button, completing directly from akonadi completes correctly and reliably (after I have dismissed the sticky "unable to fetch..." message that ANY widget asking akonadi for anyting causes on my system :p)
Comment 230 Ingo Ratsdorf 2012-10-06 05:05:32 UTC
Just installed the Kubuntu 4.9.2 binaries, still no autocompletion neither in KMail nor KOrganizer.

If I enter an attendee in KOrganizer, the following appears in Akonadiconsole while typing "John":

31 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?r ?reqProp1 WHERE { ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . ?r a nco:Contact . { ?r nco:fullname ?v . ?v bif:contains \"'j'\" . } UNION { ?r nco:nameGiven ?v . ?v bif:contains \"'j'\" . } UNION { ?r nco:nameFamily ?v . ?v bif:contains \"'j'\" . } UNION { ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . ?v bif:contains \"'j'\" . } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
31 NO Item query returned empty result set 
32 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'j*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
32 OK SEARCH completed 
33 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?r ?reqProp1 WHERE { ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . ?r a nco:Contact . { ?r nco:fullname ?v . ?v bif:contains \"'jo'\" . } UNION { ?r nco:nameGiven ?v . ?v bif:contains \"'jo'\" . } UNION { ?r nco:nameFamily ?v . ?v bif:contains \"'jo'\" . } UNION { ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . ?v bif:contains \"'jo'\" . } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
33 OK SEARCH completed 
34 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'jo*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
34 OK SEARCH completed 
35 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?r ?reqProp1 WHERE { ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . ?r a nco:Contact . { ?r nco:fullname ?v . FILTER regex(str(?v), \"\\\\bjoh\", \"i\") } UNION { ?r nco:nameGiven ?v . FILTER regex(str(?v), \"\\\\bjoh\", \"i\") } UNION { ?r nco:nameFamily ?v . FILTER regex(str(?v), \"\\\\bjoh\", \"i\") } UNION { ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . FILTER regex(str(?v), \"\\\\bjoh\", \"i\") } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
35 NO Item query returned empty result set 
36 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'joh*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
36 OK SEARCH completed 
37 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?r ?reqProp1 WHERE { ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . ?r a nco:Contact . { ?r nco:fullname ?v . FILTER regex(str(?v), \"\\\\bjohn\", \"i\") } UNION { ?r nco:nameGiven ?v . FILTER regex(str(?v), \"\\\\bjohn\", \"i\") } UNION { ?r nco:nameFamily ?v . FILTER regex(str(?v), \"\\\\bjohn\", \"i\") } UNION { ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . FILTER regex(str(?v), \"\\\\bjohn\", \"i\") } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
37 NO Item query returned empty result set 
38 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'john*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
38 OK SEARCH completed 
39 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName \"john\"^^<http://www.w3.org/2001/XMLSchema#string>. } }" FULLPAYLOAD EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
39 OK SEARCH completed 

However, I have no indication whether that search actually returns anything. I have also tried various searches in Aknadi Console and they ALL give no return whatsoever, even when using some of the "predefined" ones, just replacing "Tobias Koenig" for example with my name.

So may it be that it is some Akonadi/Virtuoso issue? I could not find any manuals for Akonadi/Virtuoso query format. Not even sure who is querying whom in what language here.... ;-)
Comment 231 Erasmo Caponio 2012-10-06 06:46:22 UTC
For me, autocompeltion has begun to work starting from kde 4.9.0 (with Kubuntu 12.04).
It seems to find all the entries in my google contacts after typing the first letter of a name or a surname or a email adresses domain. 
I would like to tell that, beginning with kde 4.9.0, I have always updated kde in a console, without having started a kde session, without akonadi and nepomuk services running (maybe this can explain why for someone works and for others not).
Comment 232 Anders Lund 2012-10-06 07:26:08 UTC
(In reply to comment #231)
> I would like to tell that, beginning with kde 4.9.0, I have always updated
> kde in a console, without having started a kde session, without akonadi and
> nepomuk services running (maybe this can explain why for someone works and
> for others not).

What do you mean by "updated"?
Comment 233 Erasmo Caponio 2012-10-06 07:33:52 UTC
(In reply to comment #232)
> (In reply to comment #231)
> > I would like to tell that, beginning with kde 4.9.0, I have always updated
> > kde in a console, without having started a kde session, without akonadi and
> > nepomuk services running (maybe this can explain why for someone works and
> > for others not).
> 
> What do you mean by "updated"?

to pass from kde 4.8.x  to kde  4.9.0 and so on, using apt
Comment 234 Paul Gideon Dann 2012-10-17 10:38:09 UTC
This blog post mentions work being done on address completion at the recent PIM sprint:
http://pusling.com/blog/?p=261
Comment 235 Dimitrios Glentadakis 2012-10-17 17:59:42 UTC
*** Bug 297795 has been marked as a duplicate of this bug. ***
Comment 236 Sérgio Basto 2012-11-01 18:34:30 UTC
(In reply to comment #226)
> (In reply to comment #225)
> > What are you guys doing so that autocompletion works? It does not work for
> > me at all, using KDE Ubuntu binaries 4.9.1.
> > Autocompletion by dropdown, corect addressbook order, krunner can find
> > contacts...
> > ....just not KMail or KOrganiser.
> > 
> > What's wrong?
> > 
> > I have nepomuk semantic desktop enabled, however file and email indexing
> > disabled since I definitely do not need it or want it on the laptop.
> 
> you have to shake the machine :) 
> 
>  Try to reenable initial indexing in
>  ~/.kde4/share/config/akonadi_nepomuk_feederrc:
>  "InitialIndexingComplete=false"
>  and restart Akonadi: # akonadictl restart
>  
>  This worked for me with 4.9.1!
> 
> I just disable Nepomuk file indexer

Now ,  when I choose a 3 different letters , I see virtuoso-t up to 100% of CPU 

26268 sergio    39  19  634m 274m 6972 S 99.2  7.2   1:07.47 virtuoso-t                                

and after 10 seconds I got the result, with kdelibs-4.9.2-5.fc17.x86_64 series
Comment 237 Rigo Wenning 2012-11-09 17:00:01 UTC
With KDE 4.9.1 auto completion started to work again. But it is not reliable. Some addresses are shown, some aren't. I can't detect why. Now on KDE 4.9.2 "release 511" on OpenSuse 12.2. but no change. 
De-activating an address book in Kontact's address book doesn't change the behavior. It always completes the same way, whatever I tell it to do in "change completion order". I have some addresses that never appear in the completion, but as was reported, the "select" dialog and the address book itself work reliably.

I think the developers should decouple address completion from nepomuk and only put nepomuk back in the way once it works. The algo in KDE 3.5.9 worked fast on several thousand addresses. Could that be a quick fix until the other stuff is mature?
Comment 238 Ingo Ratsdorf 2012-11-11 20:41:50 UTC
I am now on 4.9.3 and still no autocompletion, neither in KMail nor KOrganiser Attendees.
I use only remote Akonadi CardDAV Addressbook. Can that influence the search?
Comment 239 Dimitrios Glentadakis 2012-11-15 06:03:58 UTC
*** Bug 310082 has been marked as a duplicate of this bug. ***
Comment 240 Paul 2012-11-15 21:55:57 UTC
After upgrading to KDE 4.9.3 I have deleted and recreated the akonadi nepomuk feeder from akonadi console. I also set InitialIndexingComplete to false as mentioned in earlier posts. It's rebuilding now, and I'm getting autocompletion from contacts found in my data and the shared addessbook, but not from my personal addressbook (yet).
Comment 241 Mathias Homann 2012-11-20 16:26:49 UTC
KDE 4.9.3 on opensuse... for a short while I had working autocompletion, now it stopped working again.

On a related note, nepomuk refuses to start.
Comment 242 regi.hops 2012-12-02 13:51:51 UTC
After resetting Nepomuk/Akonadi multiple times and trying different address-book types - like the Personal, Kolab, DAV-Groupware - I identified 4 VCards in my address-book that were never found through auto-completion.
Starting from scratch and importing my VCards it took every time nearly 24 hours until auto-completion started to work (?) - except for those mentioned VCards.
Even on different computers they were never found through auto-completion.

So if one of the developer would like to have them for debugging purposes, please send me an email - preferably from a verifiable account.
Because of legal data-privacy reasons I can't and won't post them here.

Cheers
Regi
Comment 243 Eugene Shalygin 2012-12-04 18:43:04 UTC
I have the same issue as many of users here: autocompletion from Google contacts does not work, but contacts are accessible via "Select" button. I always had Nepomuk enabled, but e-mail indexing disabled. After I disabled Nepomuk completely some time ago, adresses autocompletion started to work. Enabling the Nepomuk breaks autocompletion.

KDE 4.10 beta 1
Comment 244 Eugene Shalygin 2012-12-05 19:11:02 UTC
After disabling the e-mail feeder plugin (by removing /usr/share/kde4/services/nepomukmailfeeder.desktop), I was able to wait until the feeder managed to index all my contacts and calendars. After that, the situation is the same: with Nepomuk turned off completion works, with Nepomuk turned on --- does not
Comment 245 Cédric Bellegarde 2012-12-05 19:28:26 UTC
>with Nepomuk turned off completion works

https://git.reviewboard.kde.org/r/105810/
Comment 246 Eugene Shalygin 2012-12-05 19:47:40 UTC
Oh, thank you! Excellent change, IMO. This Soprano/Nepomuk stuff is simply unusable...
Comment 247 Richard Homonnai 2012-12-09 21:18:15 UTC
(In reply to comment #245)
> >with Nepomuk turned off completion works
> 
> https://git.reviewboard.kde.org/r/105810/

Does not apply anymore with 4.9.3 - or is it just me? :(
Comment 248 Ingo Ratsdorf 2012-12-09 21:35:24 UTC
KDE 4.9.3 now too.
I have disabled akonadi_nepomuk_feeder.desktop and some addresses seem to be working now. But only some.

Family members, about 12, all with the same surname "ratsdorf" in all the same remote DAV address book. If I start typing "rats", 2 show up, not 12. If I hit backspace in the search text field (now showing "rat"), suddenly 4 show up, but still no 12.

Totally puzzled.

I am failing to see this whole nepomuk/soprano/virtuoso stuff, when all the data is stored in akonadi aka SQL database already.
I would think that a "SELECT * FROM akonadi_contacts LIKE "rats"; would certainly deliver the required resuts, NO? You see where I am coming from?
Comment 249 avlas 2012-12-28 05:01:24 UTC
It was working for me in kde 4.9 but not anymore in kde 4.10rc1. I had to disable nepomuk to workaround the issue.
Comment 250 Hans-Peter Jansen 2013-01-07 11:13:09 UTC
Problem persists with 4.9.5 here from K:R:49 (openSUSE 12.2).

Only recent used mail addresses get autocompleted correctly and _some_ ldap entries, but neither any vcard folder, nor from my google account.

The question is, when will this DE/pim suite be usable again?
Comment 251 Cédric Bellegarde 2013-01-07 11:28:01 UTC
@Hans-Peter Jansen 

In KDE 4.10, if you disable nepomuk...

With nepomuk, issue seems harder to catch....
Comment 252 Anders Lund 2013-01-07 11:31:46 UTC
Very sad - I appear to be hit by this one again, using kde 4.10 rc2 :(
Comment 253 m.wege 2013-01-07 11:42:42 UTC
This bug is really old and I really do not understand why it does not seem to have any kind of priority. Using an addressbook is from my understanding one of the key functions of an email programme. I have moved to Thunderbird a year ago, not very happy about this (I now maintain two addressbooks since Thunderbird does not support Akonadi), so I would be really looking forward to move back to Kmail when this and https://bugs.kde.org/show_bug.cgi?id=259813 are fixed.
Comment 254 Rigo Wenning 2013-01-10 17:36:13 UTC
Address completion works for me now: 4.9.4 "release 5" on OpenSuse 12.2 with kernel 3.7.0-rc3-2-desktop. 

In akonadi_nepomuk_feederrc I changed  IndexCompatLevel=3 to IndexCompatLevel=1 (I don't think that changed anything).  Mainly, I kept akonadiconsole open. And every time the Akonadi Nepomuk Feeder said "System busy, indexing suspended" I restarted the agent in the interface. This finally brought all the information to nepomuk. Virtuoso was hammering my system with a load of 300 for a day (quadcore) and using up all memory. Additionally, I made this very useful change as suggested by the ArchLinux Wiki: https://wiki.archlinux.org/index.php/KDE recommending to say: 
echo "fs.inotify.max_user_watches = 524288" >> /etc/sysctl.conf
And suddenly, after a day of thinking, nepomuk seems to start to feed address completion into my system. This works for a vcard file, for personal contacts and for a CardDAV resource. 
Conclusion: The system is ok, but the Akonadi Nepomuk Feeder seems to be very fragile and breaks every 10min or so as it doesn't digest what the system is feeding through it. If someone would sanitize the input into Akonadi Nepomuk Feeder and make it a bit more robust, that would probably solve it.
Comment 255 Rigo Wenning 2013-01-10 17:38:59 UTC
Address completion works for me now: 4.9.4 "release 5" on OpenSuse 12.2 with kernel 3.7.0-rc3-2-desktop. 

In akonadi_nepomuk_feederrc I changed  IndexCompatLevel=3 to IndexCompatLevel=1 (I don't think that changed anything).  Mainly, I kept akonadiconsole open. And every time the Akonadi Nepomuk Feeder said "System busy, indexing suspended" I restarted the agent in the interface. This finally brought all the information to nepomuk. Virtuoso was hammering my system with a load of 300 for a day (quadcore) and using up all memory. Additionally, I made this very useful change as suggested by the ArchLinux Wiki: https://wiki.archlinux.org/index.php/KDE recommending to say: 
echo "fs.inotify.max_user_watches = 524288" >> /etc/sysctl.conf
And suddenly, after a day of thinking, nepomuk seems to start to feed address completion into my system. This works for a vcard file, for personal contacts and for a CardDAV resource. 
Conclusion: The system is ok, but the Akonadi Nepomuk Feeder seems to be very fragile and breaks every 10min or so as it doesn't digest what the system is feeding through it. If someone would sanitize the input into Akonadi Nepomuk Feeder and make it a bit more robust, that would probably solve it.
Comment 256 Ingo Ratsdorf 2013-01-10 19:30:15 UTC
In reply to the previous post: Isn't that a wee bit overkill just to have autocompletion working when such a feature is already working in KAddressbook without all that nepomuk and hammering systems? Just my personal thought.
I have a dualcore notebook and cannot and do not want to afford such procedures.
Comment 257 Mathias Homann 2013-01-10 20:59:47 UTC
well sorry, i don't think inotify is going to do me any good... my addressbook is a webdav ressource and my ~ is on NFS. and like #256 i have better things to do than this.

not completely unrelated: anyone know of a good lightning add-on for Thunderbird to have all calendars from google calendar at once, like with the akonadi google feed?
Comment 258 Dimitrios Glentadakis 2013-01-11 06:11:38 UTC
For this bug and others i would like to see nepomuk be dropped from kde
Why not have the same destiny with strigi:
http://vhanda.in/blog/2012/11/nepomuk-without-strigi/

and dolphin column view:
https://bugs.kde.org/show_bug.cgi?id=290747

Until now the politic line is: if something is hard to maintain, we drop it.
I was nt very happy when dolphin column view was dropped but i will be very happy if anything about nepomuk will be dropped.
Noone like it + nooane use it. (just google it)

On day we will have to make decisions and let users have simple features like autocompletion working.
Comment 259 postdoc38 2013-01-11 06:20:22 UTC
Amen
Comment 260 Cédric Bellegarde 2013-01-11 08:09:12 UTC
@Dimitrios Glentadakis 

If you don't want nepomuk, just disable it and completion will work (KDE 4.10)
Comment 261 Nico Kruber 2013-01-11 08:37:27 UTC
(In reply to comment #258)
> Noone like it + nooane use it. (just google it)
I know, this is probably your frustration speaking, but this is probably not true. And you must admit that it has made progress in the past releases (despite this bug).

Anyway, we should focus on getting this bug resolved...

@devs:
1) is there any way we could help?
2) what is the progress of finding the cause?
3) are there e.g. unit tests that currently test the according functionality, i.e. contacts finding and contacts indexing? If not, you could probably give some hints on where to start on this one - maybe someone here has some time to do it?
Comment 262 Paul Gideon Dann 2013-01-11 10:24:40 UTC
I want to jump in here to avoid a vocal-minority situation that might discourage the Nepomuk / KMail developers.  Sorry for the off-topic:

Although Nepomuk is still having some growing pains, and in fact I don't currently use many (if any) semantic desktop features, I think it's an awesome technology with *huge* potential.  I think Nepomuk is paradigm-shifting, and for that reason, I think it's likely that it'll see relatively low interest on the desktop until it suddenly revolutionises everyone's expectation of what the system can do, at which point everyone will wonder how they managed without it.  (Although at that point, they may well not associate these shiny features with the name "Nepomuk"; they'll just be there.)  That won't happen until everything finally "clicks", and until then it'll probably not get the recognition it deserves.  Keep going guys; you're doing awesome work, and you're doing it for free.  We're very grateful.
Comment 263 Rigo Wenning 2013-01-11 10:51:36 UTC
The use of nepomuk in gwenview e.g. is really great. I think the main error with nepomuk is to provide everything out of a (too large) database. The current complexity is not necessary IMHO. Instead, you should use the power of linked data and just store the pointers and the metadata in several very lean databases. This would avoid that I lose all my image tags because my meta-data-base was wrecked by the import of some spam email. 
Also, the way identifiers were constructed and used in KDE always surprised me. Instead of using URI and namespaces, they have used identifiers that haven't worked 10 years ago and that still don't work. While KDE 1.1 was revolutionary in its integration of Web and Desktop(yes I used that) , KDE 4 commits many sins in that respect. Perhaps this discussion will convince some to change their approach. I would welcome this. Funnily enough, on my Meego phone QT interface, it all works really well. I get a complete history of all interaction with a person within seconds on a phone! So nepomuk is not the problem. The implementation of nepomuk has to be thought through again IMHO.
Comment 264 avlas 2013-01-13 23:23:01 UTC
Don't know how or why, but misteriously it's working again here in kde 4.10 rc2, perhaps nepomuk needed extra time to update something or to be restarted in some way...
Comment 265 Eugene Shalygin 2013-01-15 17:51:05 UTC
I've finally desided to debug it today. In my case I've found and fixed the problem. Maybe, it will help someone else.

What I've found: AddresseeLineEdit::Private::startNepomukSearch() (it is in libkdepim/addresseelineedit.cpp) has two conditions for invoking Nepomuk-based completion:
1) length of the query string is 3 chars or longer, and
2) s_static->useNepomukCompletion is true.
In my case s_static->useNepomukCompletion was always false. Where it comes from? It is loaded from KConfig("kpimcompletionorder"). The value is read from section "General", key "UseNepomuk".
I opened my ~.kde4/share/config/kpimcompletionorder and saw that it even does not contain section "General"!
Then I tried to find who sets this value. Search of string "UseNepomuk" in kdepim sources gave only one location where it is readed.  Nobody writes? Ok, I can do it by myself... And after that completion started to work!

So, summary:
1. Open  ~.kde4/share/config/kpimcompletionorder
2. Appendkmail there:
[General]
UseNepomuk=true

3. Close file

But completion is not perfect :( It can not find persons by second name, by family name in some cases...
Comment 266 Eugene Shalygin 2013-01-15 18:01:43 UTC
Sorry, hit "send" accidently.
So, it helped me too (the same solution was reported before already in previous comments).

So, I was going to say: is it really no method to write this parameters via KMail configuration interface? If so, developers, how that is possible?
Comment 267 Eugene Shalygin 2013-01-15 22:51:02 UTC
After debugging Akonadi completion (that pointed out to the wrong sparql query) with my 4.9.97 version, I was very happy to see that exectly this problem was fixed in master a few days ago (http://commits.kde.org/kdepimlibs/ecd1745ddafa08c24473e33800edd5c31f92bd98)!

The changeset applies to 4.9.97 and works! Thank you, Vishesh!
Comment 268 quazgar 2013-01-15 23:24:04 UTC
(In reply to comment #267)
> The changeset applies to 4.9.97 and works! Thank you, Vishesh!

If this promises to fix the bug, could it be backported to 4.9?  That would allow faster confimation/rejection by a larger population, especially since this bug appears to be partly non-deterministic according to the comments (works here, doesn't work there, now it doesn't work here any longer, ...).
Comment 269 Sérgio Basto 2013-01-15 23:32:02 UTC
(In reply to comment #268)
> (In reply to comment #267)
> > The changeset applies to 4.9.97 and works! Thank you, Vishesh!
> 
> If this promises to fix the bug, could it be backported to 4.9?  That would
> allow faster confimation/rejection by a larger population, especially since
> this bug appears to be partly non-deterministic according to the comments
> (works here, doesn't work there, now it doesn't work here any longer, ...).

Totally agree with this sentence 
Now it doesn't work here any longer with kdepim-4.9.5-1.fc17.x86_64 .
People of KDE should think in some stability.
Comment 270 Ingo Ratsdorf 2013-01-16 00:07:44 UTC
Agree, please backport. We would really love to have a working system before 4.10.
If that really fixes it, then thank you, Vishesh! It's been a long time....
Comment 271 m.wege 2013-01-16 09:25:55 UTC
Unfortunately the described solution adding the [General] section has no effect with my installation. Not even after a restart. 
May be it has something to do with the face that I have more than one Akonadi-addressbook?
I somebody tells me what to do, I would help debugging.
Comment 272 Eugene Shalygin 2013-01-16 09:56:53 UTC
(In reply to comment #271)
> I somebody tells me what to do, I would help debugging.
To debug Akonadi Completion, you can start with AkonadiConsole. Enable debugging there. Start KMail. Initiate completion. Find completion client sub-tab in debugger tab (it will have seld describing name). Find there a contact search command (there are two commands in 4.9.97: contact search followed by group search). The command looks like "SEARCH "<query>" flags". There you will see results of the query (IDs of returned objects). You can copy the query to the "Item Search" tab of Akonadi Console, replace escape sequences (basically, \" with " and \\ with \) and execute it. 

You will see result objects there.

In master branch the query string is:
SELECT DISTINCT ?r ?reqProp1 
WHERE { ?r<http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . 
{ ?r ?p ?v . FILTER(?p in (nco:fullname, nco:nameGiven, nco:nameFamily) ) .
FILTER regex(str(?v), "\\b<search string>", "i") } 
UNION 
{ ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . 
FILTER regex(str(?v), "\\b<search string>", "i") } }

The problem for me was in absent "UNION" keyword.
<search string> has to be replaced with your value, like Doe 
If you are using 4.9, then, as I understand, you must prepend query with
prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>

So it will look like this:
prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>
SELECT DISTINCT ?r ?reqProp1 
WHERE { ?r<http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . 
{ ?r ?p ?v . FILTER(?p in (nco:fullname, nco:nameGiven, nco:nameFamily) ) .
FILTER regex(str(?v), "\\bDoe", "i") } 
UNION 
{ ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . 
FILTER regex(str(?v), "\\bDoe", "i") } }
Comment 273 Ingo Ratsdorf 2013-01-16 10:46:29 UTC
On my system (ubuntu, KDE 4.9.5) the following happens:

kmail2-xxxxxxxx tab:
161 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?r ?reqProp1 WHERE { ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . ?r a nco:Contact . { ?r nco:fullname ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } UNION { ?r nco:nameGiven ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } UNION { ?r nco:nameFamily ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } UNION { ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
161 NO Item query returned empty result set 
162 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'Ingo*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
162 OK SEARCH completed 

That's a lot of UNIONS however still no results despite of several "Ingos"s in the contacts. All it lists are the recent contacts.
My knowledge of SQL and the like is limited, but that's a terrible construct and a lot of backslashes...
Comment 274 Eugene Shalygin 2013-01-16 11:32:25 UTC
(In reply to comment #273)
I can not see anything wrong with that query.
Could you, please, to be sure execute it from Item Search tab?
I've removed escape sequences for you.

prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>
SELECT DISTINCT ?r ?reqProp1 
WHERE 
{ ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . 
?r a nco:Contact . 
{ ?r nco:fullname ?v . FILTER regex(str(?v), "\\bIngo", "i") }
 UNION 
{ ?r nco:nameGiven ?v . FILTER regex(str(?v), "\\bIngo", "i") } 
 UNION 
{ ?r nco:nameFamily ?v . FILTER regex(str(?v), "\\bIngo", "i") }
 UNION 
{ ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . FILTER regex(str(?v), "\\bIngo", "i") } }

If it will not return anything, you can check with nepomukshell (NepSaK) existence of  contacts in nepomuk storage
Comment 275 Ingo Ratsdorf 2013-01-17 09:34:47 UTC
in reply to comment #274:

Entered your query into Akonadiconsole search and below is the result in debug view:

akonadiconsole-489035169 (0x96b6b70) 3 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>\nSELECT DISTINCT ?r ?reqProp1 \nWHERE \n{ ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . \n?r a nco:Contact . \n{ ?r nco:fullname ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") }\n UNION \n{ ?r nco:nameGiven ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } \n UNION \n{ ?r nco:nameFamily ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") }\n UNION \n{ ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . FILTER\nregex(str(?v), \"\\\\bIngo\", \"i\") } }" EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
akonadiconsole-489035169 (0x96b6b70) 3 NO Item query returned empty result set 

I have however changed kpimcompletion and added the missing line and restarted the computer. And VOILA, AUTOCOMPLETION in now WORKING!

However, despite of the working autocompletion, Akonadiconsole is still showing no results while typing in KMail:

348 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?r ?reqProp1 WHERE { ?r <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?reqProp1 . ?r a nco:Contact . { ?r nco:fullname ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } UNION { ?r nco:nameGiven ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } UNION { ?r nco:nameFamily ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } UNION { ?r nco:hasEmailAddress ?email . ?email nco:emailAddress ?v . FILTER regex(str(?v), \"\\\\bIngo\", \"i\") } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
348 NO Item query returned empty result set 
349 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'Ingo*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
349 OK SEARCH completed 

So no idea why akonadiconsole is showing nothing while completion works nevertheless....
Comment 276 Hans-Peter Jansen 2013-01-17 11:04:28 UTC
Created attachment 76527 [details]
Attempt to fix autocompleter for 4.9.5

Hi guys,

here's an attempt to improve this on 4.9.5. It shows some contacts for me, at least.
For those of you running openSUSE 12.{1,2}, you can try my kdepimlibs4 build from:

https://build.opensuse.org/project/show?project=home%3Afrispete%3Abranches%3AKDE%3ARelease%3A49

If you do, give feedback, please. Thanks.
Comment 277 Ralph Moenchmeyer 2013-01-17 11:56:22 UTC
> (In reply to comment #267 and comment #267)
> 
> If this promises to fix the bug, could it be backported to 4.9?  That would
> allow faster confimation/rejection by a larger population, especially since
> this bug appears to be partly non-deterministic according to the comments
> (works here, doesn't work there, now it doesn't work here any longer, ...).

Reading the latest comments I understand that some people have/had problems with autocompletion for KDE versions 4.9.X  [ with X<=5]. 

In contrast to all these experiences I want to state that in my case (Opensuse 12.2 / 12.1 with  continuous updates from KDE 4.8.4 to 4.9.5 )  autocompletion  worked smoothly since KDE 4.9.0 for all my addressbooks (local personal addressbooks,  several OX6-adressbooks).  

The things I did are described in 
* comment #184  (total clean akonadi setup after upgrade to KDE 4.9 from 4.8)  
* comment #191
* comment #217 ( setting "InitialIndexingComplete=false" and reindexing when updating to  
KDE 4.9.1). 

After that I never had to change anything despite all KDE changes up to KDE 4.9.5. And autocompletion works as expected ... (The limitations described in comment #200 still exist - but they are no show stoppers.)  

So, why does autocompletion work on some systems with KDE 4.9.X and on some not ?
Comment 278 Anders Lund 2013-01-17 12:11:02 UTC
Searching for "Peter" in kmail composer address field:

63 OK SEARCH completed 
64 SEARCH "prefix nco:<http://www.semanticdesktop.org/ontologies/2007/03/22/nco#>SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'Peter*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
64 OK SEARCH completed 

My addressbook contains 4 people named "Peter"


akonadi_nepomuk_feederrc:

[InitialIndexing]
IndexCompatLevel=3
InitialIndexingComplete=false

[akonadi_nepomuk_email_feeder]
Enabled=true

Comment: I set InitialIndexingComplete to 'false', and have been restarting kde more than once since that.

My addressbooks are stred in owncloud, and accessed via carddav using the appropriate akonadi resource.
Comment 279 Anders Lund 2013-01-17 12:13:20 UTC
Torsdag den 17. januar 2013 12:11:02 
skrev du:
> My addressbook contains 4 people 
named "Peter"

... none of which are found, in case 
anyone doubts
Comment 280 Ralph Moenchmeyer 2013-01-17 14:51:34 UTC
(In reply to comment #278)
> [InitialIndexing]
> IndexCompatLevel=3
> InitialIndexingComplete=false
> 
> [akonadi_nepomuk_email_feeder]
> Enabled=true
> 
> Comment: I set InitialIndexingComplete to 'false', and have been restarting
> kde more than once since that.
>
Just as an idea: 
In my case I had to wait quite a long time ( as far as I remember several hours ) to get the reindexing finished. (This long period was due to tons of mails on the IMAP-Server.)
During that time I did not log out or reboot. I restarted  KDE/Kontact/Akonadi only after the system had changed "InitialIndexingComplete" to "true". I waited because I never was sure,  what kind of effects could result from an interruption of the reindexing process.
Comment 281 Sérgio Basto 2013-01-17 21:51:46 UTC
(In reply to comment #276)
> Created attachment 76527 [details]
> Attempt to fix autocompleter for 4.9.5
> 
> Hi guys,
> 
> here's an attempt to improve this on 4.9.5. It shows some contacts for me,
> at least.
> For those of you running openSUSE 12.{1,2}, you can try my kdepimlibs4 build
> from:
> 
> https://build.opensuse.org/project/
> show?project=home%3Afrispete%3Abranches%3AKDE%3ARelease%3A49
> 
> If you do, give feedback, please. Thanks.

did you try (http://commits.kde.org/kdepimlibs/ecd1745ddafa08c24473e33800edd5c31f92bd98)! 
before ?
Comment 282 Sérgio Basto 2013-01-17 22:44:58 UTC
Hi, sorry for the noise , but after last reboot , autocompletion with addressbook start working again in kdepim-4.9.5-1.fc17.x86_64 , I think I don't update nothing .
Comment 283 Mathias Homann 2013-01-18 08:57:04 UTC
(In reply to comment #276)
> Created attachment 76527 [details]
> Attempt to fix autocompleter for 4.9.5
> 
> Hi guys,
> 
> here's an attempt to improve this on 4.9.5. It shows some contacts for me,
> at least.
> For those of you running openSUSE 12.{1,2}, you can try my kdepimlibs4 build
> from:
> 
> https://build.opensuse.org/project/
> show?project=home%3Afrispete%3Abranches%3AKDE%3ARelease%3A49
> 
> If you do, give feedback, please. Thanks.

I've installed those on openSUSE 12.2 with KDE 4.9,5 from K:R:49, did not change anything.
Comment 284 Ingo Ratsdorf 2013-01-18 09:08:50 UTC
Further to comment #275:

On my system (ubuntu, KDE 4.9.5), autocompletion is working since I added
[General]
UseNepomuk=true

to ~.kde4/share/config/kpimcompletionorder

My other settings are:
=======================
Systemsettings -> Desktop Search:
Enable Nepomuk Semantic Desktop
Disable Nepomuk File Indexer
Disable Email Indexer

System Settings -> Startup and Shutdown:
[Service Manager], Startup Services
Enable Nepomuk Search Module

Config files
~/.kde/share/config/nepomukserverrc:
[Basic Settings]
Start Nepomuk=true

~/.kde/share/config/akonadi_nepomuk_feederrc:
[akonadi_nepomuk_email_feeder]
Enabled=false
Comment 285 regi.hops 2013-01-20 21:58:52 UTC
OK-guy's I think I've found something.

It seems there are several problems/bugs playing together:

1. The Akonadi Nepomuk Feeder
I set up a new system with openSUSE 12.2 and KDE 4.9.5 applied all patches and then setup IMAP, Kolab-Addressbook, and a Personal Addressbook.
In both addressbooks I import a bunch of VCF-Cards.
Autocompletion - none.
After 24h system uptime still no autocompletion.
And now what helped me:
- Reboot
- Start Kontact and connect to IMAP
- Start "akonadiconsole"
- Select Akonadi Nepomuk Feeder and choose "Restart".
!!!After clicking "Restart" don't move the mouse or touch the keyboard!!!
- Wait until the indexer is finished

Autocompletion works, but...

2. Autocompletion does not find all addresses
This was weird:
- Start Kontact and select Addressbook
- Start "akonadiconsole" and select tab "Browser"
- Choose your Addressbook and open the tab "RDF" in the second tab row
- Browse your contacts one by one
- Contacts which have "Class Name: Resource" will not be found
- Open this entry in your addressbook and check if you entered something in the three fields under E-Mail
- In my case it was enough to delete the website address and save the contact
After that selecting the contact again in "akonadiconsole" shows all data and "Class Name: PersonContact"
Now you can enter the website address again.

Conclusion:
The Akonadi Nepomuk Feeder does not reliable start the indexing in a timely manner - I don't know why, but to speed up the process use "akonadiconsole" as described above.

Autocompletion itself is working - after indexing is complete.

But entering/importing a NEW contact with a website address (or may be other fields set) will result in a none "PersonContact".
You can only enter this information in an already existing contact.

Another thing - it seems that only addressbooks/folders are indexed that are checked (checkbox) in the addressbook, at least in my case I let my Personal-Addressbook unchecked and it was not indexed.


So after all autocompletion is working now 100% for me - but somebody of the dev's should have a close look at this.

Cheers 
Regi
Comment 286 Eugene Shalygin 2013-01-21 17:19:26 UTC
(In reply to comment #285)
The necessity to restart indexer in Akonadi might be related to the problem which is discussed in #312680. At least, when I add a scipt to Pre-KDE startup that starts nepomukserver and waits until Nepomuk creates its socket, indexing agent works (and Plasma runner also). Unfortunetely, this mess something in the environment and Plasma starts with incorrect icons in the system tray...
Also, if indexer has option "Disable Idle Timeout" disabled (so the idle timeout is active), naturally Nepomuk has time to become operational and indexing works automatically. But, of course, only after the system becomes idle.
Comment 287 regi.hops 2013-01-21 21:12:00 UTC
(In reply to comment #286)

Sigh - seems you're right.
After I read your comment I added a new contact and it doesn't show up until I restart the feeder.
After that, adding more contacts works.
OK - Until 4.10 is out I can live with that, I usually don't add new contacts daily ;-)

For me it was important that the autocompletion search shows all relevant contacts, and that seems to work now.
But - it's a mess with all these.
Comment 288 Anders Lund 2013-01-21 21:17:09 UTC
No signs of improvements in this respect KDE 4.10, at least here, I have no autocompletion at all  using kde 4.10 rc3
Comment 289 Till Adam 2013-01-21 21:24:44 UTC
Anders, that's likely a temporary regression introduced by some of Vishesh's optimizations, fixed with ecd1745ddafa08c24473e33800edd5c31f92bd98.
Comment 290 Anders Lund 2013-01-21 21:31:21 UTC
Till: It would be great to have it working, apart from that, for me kmail is actually back on par - at least - by now :)
Comment 291 Eugene Shalygin 2013-01-21 21:43:00 UTC
(In reply to comment #289)
But ecd1745ddafa08c24473e33800edd5c31f92bd98 went into 4.10 RC3, didn't it?
Comment 292 Rigo Wenning 2013-01-23 12:32:54 UTC
(In reply to comment #285)
> - Contacts which have "Class Name: Resource" will not be found
> - Open this entry in your addressbook and check if you entered something in the three fields under E-Mail
> - In my case it was enough to delete the website address and save the contact
> After that selecting the contact again in "akonadiconsole" shows all data and "Class Name: PersonContact"
> Now you can enter the website address again.

I looked at it. The ClassName:Resource just says it is a URI. Then it points to the record-number akonadi://?item=2382 in akonadi's mysql database. Apparently, there is a bug in the search there that affects not only autocompletion, but also other use cases (like email refs in to dos) that search items inside the akonadi mysql base. So naming and retrieving URIs in KDE PIM is a larger prob unearthed by this bug. The DevOps should really think about a common naming convention for KDE PIM that survives moving things from one address book to another and from one email folder to another without creating one big database.
Comment 293 Thomas Iguchi 2013-01-28 17:21:33 UTC
I have auto-completion problems with both versions 4.8.5 and 4.9.5. Local address books work without a problem (if they are checked / activated in KAddressbook). However, I'm also using a remote address book source based on CalDAV run on an ownCloud server. Auto-completion does not work for this one.
Comment 294 Anders Lund 2013-01-30 10:24:28 UTC
Today, for unknown reason, kmail composer completes some of my contacts. Nowhere near all, though, SOME.

How did you chose which to index, and why not index all?

Why is this so chaotic? There must be a way to ensure that contacts are indexed!

This experience is horrible, because it is not trustworthy. I'd rather have NO completion than BROKEN completion!

Why is there still not a way to use the simple way of completing, when obviously you are not able to provide using nepomuk for several years? I use nepomuk for other things fine, but kmail is BROKEN in this respect! :(
Comment 295 Graeme Hewson 2013-01-30 11:04:54 UTC
I can reproduce / work around part of the problem like this. I have one address book, a local one. It has one entry only, with a single name (no surname) in the Name and Display fields, and an entry of the form firstname.lastname@gmail.com.  "Name" is not in "firstname" or "lastname".

1. Edit Recent Addresses (alt-click in To field of new message) and remove all recent addresses.
2. Stop and restart Kontact.
3. Start a new message.
4. Type Name slowly in the To field. At no point does Kmail suggest the address book entry.
4. Clear the To field and start to type firstname. Kmail suggests the address book entry (as expected).
5. Clear the To field and start to type Name. This time Kmail suggests the address book entry, as expected, but this isn't what happened in step 4.
6. Address book completion continues to work for Name until Kontact is restarted (step 1).

Using 4.9.5.
Comment 296 Anders Lund 2013-01-30 11:12:24 UTC
Onsdag den 30. januar 2013 11:04:54 skrev du:
> https://bugs.kde.org/show_bug.cgi?id=259949
> 
> --- Comment #295 from Graeme Hewson <bugs@wormhole.me.uk> ---
> I can reproduce / work around part of the problem like this. I have one
> address book, a local one. It has one entry only, with a single name (no
> surname) in the Name and Display fields, and an entry of the form
> firstname.lastname@gmail.com.  "Name" is not in "firstname" or "lastname".
> 
> 1. Edit Recent Addresses (alt-click in To field of new message) and remove
> all recent addresses.
> 2. Stop and restart Kontact.
> 3. Start a new message.
> 4. Type Name slowly in the To field. At no point does Kmail suggest the
> address book entry.
> 4. Clear the To field and start to type firstname. Kmail suggests the
> address book entry (as expected).
> 5. Clear the To field and start to type Name. This time Kmail suggests the 
> address book entry, as expected, but this isn't what happened in step 4.
> 6. Address book completion continues to work for Name until Kontact is
> restarted (step 1).
> 
> Using 4.9.5.

That is worse than nothing, it would be faster having kaddresbook running and 
copying addresses over. Or using the broken dialog hidden in the "..." button for each 
field (this dialog USED to allow to add multiple adressees, but not so anymore :( - but 
it is still non-chaotic, safe way to find addressees)
Comment 297 Eggert Ehmke 2013-01-30 11:12:45 UTC
May it be simple a performance issue? Sometimes the completion  works as 
expected, sometimes it takes a long time like 10 or 20 seconds to complete. So 
it works, but a user would expect immediate response and complains "does not 
work". This is Gentoo on AMD64 with KDE 4.9.5.

Eggert

Am Mittwoch, 30. Januar 2013, 11:04:54 schrieben Sie:
> https://bugs.kde.org/show_bug.cgi?id=259949
> 
> --- Comment #295 from Graeme Hewson <bugs@wormhole.me.uk> ---
> I can reproduce / work around part of the problem like this. I have one
> address book, a local one. It has one entry only, with a single name (no
> surname) in the Name and Display fields, and an entry of the form
> firstname.lastname@gmail.com.  "Name" is not in "firstname" or "lastname".
> 
> 1. Edit Recent Addresses (alt-click in To field of new message) and remove
> all recent addresses.
> 2. Stop and restart Kontact.
> 3. Start a new message.
> 4. Type Name slowly in the To field. At no point does Kmail suggest the
> address book entry.
> 4. Clear the To field and start to type firstname. Kmail suggests the
> address book entry (as expected).
> 5. Clear the To field and start to type Name. This time Kmail suggests the
> address book entry, as expected, but this isn't what happened in step 4.
> 6. Address book completion continues to work for Name until Kontact is
> restarted (step 1).
> 
> Using 4.9.5.
Comment 298 Anders Lund 2013-01-30 11:18:15 UTC
Onsdag den 30. januar 2013 11:12:45 skrev du:
> --- Comment #297 from Eggert Ehmke <eggert.ehmke@berlin.de> ---
> May it be simple a performance issue? Sometimes the 
completion  works as 
> expected, sometimes it takes a long time like 10 or 20 seconds to 
complete.
> So  it works, but a user would expect immediate response and 
complains
> "does not work". This is Gentoo on AMD64 with KDE 4.9.5.

It does *not* work if it takes 10-20 seconds. Oh, and I can play HD video, 
edit video and RAW photos etc on my labtop. Any other completions 
works as a charm, including complex completion of code. But not 
addressees for a mail. Performance so bad in the software would mean 
throw it away and start over, frankly! Especially considering that this 
problem have been there for years.
Comment 299 Anders Lund 2013-01-30 11:28:45 UTC
Onsdag den 30. januar 2013 11:12:45 skrev du:
> --- Comment #297 from Eggert Ehmke <eggert.ehmke@berlin.de> ---
> May it be simple a performance issue? Sometimes the completion  works as 
> expected, sometimes it takes a long time like 10 or 20 seconds to complete.
> So  it works, but a user would expect immediate response and complains
> "does not work". This is Gentoo on AMD64 with KDE 4.9.5.

Another comment to this: Performance is actually fantastic, the issue appears to 
be that my contacts are not indexed.

Typing one letter, matching contacts are immediately suggested. Since a long 
time, this meant noone, since akonadi chose to not index any contacts at all 
since i got this laptop, for reasons unknown to me. Sometime today, it decided 
to index a random selection of contacts.

CHAOS
Comment 300 Anders Lund 2013-01-30 11:44:30 UTC
What I did do today btw was running the nepomukcleaner app present in kde 4.10 rc3, maybe that got the little selection of contacts visible? But then, why not all of them?? Still, the feeling of addressee completion in kmail is CHAOS.
Comment 301 regi.hops 2013-01-30 19:39:11 UTC
(In reply to comment #299)

> Another comment to this: Performance is actually fantastic, the issue
> appears to 
> be that my contacts are not indexed.
> 
> Typing one letter, matching contacts are immediately suggested. Since a long 
> time, this meant noone, since akonadi chose to not index any contacts at all 
> since i got this laptop, for reasons unknown to me. Sometime today, it
> decided 
> to index a random selection of contacts.
> 
> CHAOS

Sounds like you have the same problems I had.
Take a look at my #Comment 285 It may could help you.
At least for the contacts you have already in your address book.
Comment 302 Anders Lund 2013-01-30 19:51:24 UTC
Interresting, but I think that the software should be responsible to do this. If the developers of akonadi and nepomuk is not able to make it index the contacts correctly so they are accessible for compltion, the software is useless for that purpose, and should not be used for it. Having to change my data in order to get it indexed is not acceptable usability.

But your hint should at least be helpful to those developers.
Comment 303 Anders Lund 2013-01-30 20:16:41 UTC
I restarted the akonadi_nepomuk_feeder agent, and it claimed to reindex all my data. After that ALL contacts are "Class name: Resource" (Before there was a mix, and I can comfirm that the contacts I saw in completions also was "Class Name: PersonContact"). The same randomly chosen contacts as before will complete.

It still feels CHAOTIC. Bad.
Comment 304 Graeme Hewson 2013-01-30 20:20:57 UTC
I think my comment 295 should be helpful to developers too (if they notice it).
Comment 305 regi.hops 2013-01-30 20:25:50 UTC
(In reply to comment #303)
> I restarted the akonadi_nepomuk_feeder agent, and it claimed to reindex all
> my data. After that ALL contacts are "Class name: Resource" (Before there
> was a mix, and I can comfirm that the contacts I saw in completions also was
> "Class Name: PersonContact"). The same randomly chosen contacts as before
> will complete.
> 
> It still feels CHAOTIC. Bad.

Sigh - Too bad. :-(
Thought it may could help - don't know why this thing behaves so differently.
Comment 306 Anders Lund 2013-01-30 20:27:53 UTC
Onsdag den 30. januar 2013 20:25:50 skrev du:
> Sigh - Too bad.
> Thought it may could help - don't know why 
this thing behaves so
> differently.

That is what makes it feel so chaotic. Beoynd 
reach...
Comment 307 m.wege 2013-01-30 23:54:38 UTC
May be this
http://vhanda.in/blog/2013/01/nepomuk-cleaner/
helps with the problem too? I am running it at the moment. I am not sure if it is hanging, because it seems hung in the process of merging contacts. I will run it overnight and then give it a try with Kmail again.
Comment 308 m.wege 2013-01-31 10:15:18 UTC
I have done some tests too after running nepomuck-cleaner:
Search term "thomas"
-> result: Only those of last used addresses
Akonadi-Console shows:
13 SEARCH "SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'t*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
Delete seach term and enter it again
-> result: last used addresses + many results of "in my data found contacts" 
21 SEARCH "SELECT DISTINCT ?group WHERE { graph ?g { ?group <http://akonadi-project.org/ontologies/aneo#akonadiItemId> ?itemId . ?group nco:contactGroupName ?v . ?v bif:contains \"'thomas*'\" } }" FULLPAYLOAD ANCESTORS 1 EXTERNALPAYLOAD (UID REMOTEID REMOTEREVISION COLLECTIONID FLAGS SIZE DATETIME) 
21 OK SEARCH completed 
-> this new.
The first time I tried this, it also showed one result out of my contacts (even though there is more than one), unfortunately I could not save the akonadi-console output because my system crashed (unrelated) and this is not reproducible.  
The results show from my data where pretty blown up, showing duplicates. 

So at the moment it appears to me there are at least four different bugs causing problems with address completion:
1. Result from contact data and addressbook not showing up the first time when typing in a search term. -> might be a problem of timing, the results not showing up fast enough
2. Not all results from addressbook showing 
-> May be a problem of problems in nepomuk data base -> nepomuk cleaner got stuck while working with contacts
-> Pure speculation: May be the problem is related to special characters in the addressbook, like German umlauts. At least in other contexts I made this experience that this often was the cause.
3. Results from data show double results. This problem is minor, but would be nice if there was a solution to. Examples:
Liselotte Meier <liselotte.meier@ausgedachtedomain.de>
Liselotte Meier <Liselotte.meier@ausgedachtedomain.de>
Liselotte Meier <liselotte.Meier@ausgedachtedomain.de>
Liselotte Meier <Liselotte.Meier@ausgedachtedomain.de>
Frau Liselotte Meier <liselotte.meier@ausgedachtedomain.de>
Dr. Liselotte Meier <liselotte.meier@ausgedachtedomain.de>
Even though it is all the same email address, they all show up in results. Ideally there should be only one result showing up and if that result is in addressbook, it should not show up at all.
4. it appears that at least old installations do not automatically activate search completion, so it must be done manually. It would make sense if eventually broken configurations get fixed on an update. 

There appear to be more related bugs. I suggest, that in this bug, we try to differentiate them from each other and create separate bug reports which depend on this. This could hopefully make it easier for developers to make sense out of it.
Comment 309 Christian Mollekopf 2013-01-31 12:44:23 UTC
(In reply to comment #308)

First off, thanks a lot for taking the time of investigating, and sorry this issues takes so long. We're slowly getting there. I'm aware of the issue and will tackle it, as soon as I can, unfortunately work and exams kept me from getting this fully fixed for 4.10.0. We nevertheless made quite some progress on the feeders and the autocompletion, so I'm confident we'll be able to finally fix this soonish.
I'll be mostly away for the next 3 weeks, but afterwards we'll clean this mess up ;-)
I'll also try to blog about the current state of the indexers and the related autocompletion.

> 1. Result from contact data and addressbook not showing up the first time
> when typing in a search term. -> might be a problem of timing, the results
> not showing up fast enough

Yeah, it's a timing issue. I reproduced that one already but didn't manage to track it down yet. See bug 314181.

> 2. Not all results from addressbook showing 
> -> May be a problem of problems in nepomuk data base -> nepomuk cleaner got
> stuck while working with contacts
> -> Pure speculation: May be the problem is related to special characters in
> the addressbook, like German umlauts. At least in other contexts I made this
> experience that this often was the cause.

If you could report a separate bug report for that and link it to this one, that would be great. Bonus points for reproducible testcases.

> 3. Results from data show double results. This problem is minor, but would
> be nice if there was a solution to. Examples:
> Liselotte Meier <liselotte.meier@ausgedachtedomain.de>
> Liselotte Meier <Liselotte.meier@ausgedachtedomain.de>
> Liselotte Meier <liselotte.Meier@ausgedachtedomain.de>
> Liselotte Meier <Liselotte.Meier@ausgedachtedomain.de>
> Frau Liselotte Meier <liselotte.meier@ausgedachtedomain.de>
> Dr. Liselotte Meier <liselotte.meier@ausgedachtedomain.de>
> Even though it is all the same email address, they all show up in results.
> Ideally there should be only one result showing up and if that result is in
> addressbook, it should not show up at all.

Would be a nice to have, yes, not top priority though.

> 4. it appears that at least old installations do not automatically activate
> search completion, so it must be done manually. It would make sense if
> eventually broken configurations get fixed on an update. 

There still seem to be problems with queries blocking the editor if nepomuk is enabled for some users, that's why it's currently disabled by default (better no completion than not being able to write mails).
Comment 310 m.wege 2013-01-31 13:10:41 UTC
Interesting:
Disabling Nepomuk shows nearly all contacts :-)
It does not show however contacts where the second name is the match, 
e.g. contact
Hans Thomas Meier is not shown
it also does not show 
Hans-Thomas Meier.
Comment 311 Christian Mollekopf 2013-01-31 13:40:16 UTC
(In reply to comment #310)
> Interesting:
> Disabling Nepomuk shows nearly all contacts :-)

That's because this removes the timing issue from the completion.

> It does not show however contacts where the second name is the match, 
> e.g. contact
> Hans Thomas Meier is not shown
> it also does not show 
> Hans-Thomas Meier.

It indeed seems to miss the middle name. Please file a separate bug and link it to this one.
Comment 312 Christian Mollekopf 2013-01-31 13:43:38 UTC
(In reply to comment #295)
> I can reproduce / work around part of the problem like this. I have one
> address book, a local one. It has one entry only, with a single name (no
> surname) in the Name and Display fields, and an entry of the form
> firstname.lastname@gmail.com.  "Name" is not in "firstname" or "lastname".
> 
> 1. Edit Recent Addresses (alt-click in To field of new message) and remove
> all recent addresses.
> 2. Stop and restart Kontact.
> 3. Start a new message.
> 4. Type Name slowly in the To field. At no point does Kmail suggest the
> address book entry.
> 4. Clear the To field and start to type firstname. Kmail suggests the
> address book entry (as expected).
> 5. Clear the To field and start to type Name. This time Kmail suggests the
> address book entry, as expected, but this isn't what happened in step 4.
> 6. Address book completion continues to work for Name until Kontact is
> restarted (step 1).

That's because of the mentioned timing issue, and because the completion caches it's results, so the next time you try the same name completion seems to work (as the timing issue doesn't occur). If you restart kmail the cache is cleared so you're back at 1
Comment 313 Ralph Moenchmeyer 2013-01-31 14:13:12 UTC
In reply to comment #310
> > Interesting:
> > Disabling Nepomuk shows nearly all contacts :-)
> > It does not show however contacts where the second name is the match, 
> > e.g. contact
> > Hans Thomas Meier is not shown
> > it also does not show 
> > Hans-Thomas Meier.

In my case it depends. In my external OX6-Adressbook I have a contact address with an email-address like 
antje.huber@gmx.de. 

When the contact address record  contains the email address only and no further information then I would not find this address for  "hub",  but I do find it for "ant" in Kmails address completion. 
However, after adding a first name "Antje" and a name "Huber" in the address data of my address record and restarting akonadi I do get the address in Kmail's address completion. 

So, obviously the address indexing refers to several fields of an address record and it may not handle the analysis of combined expressions with separation letters like "." in email addresses  carefully enough.  

Interesting also that I have to restart Akonadi again to see the effects of changes of an address.
Comment 314 Anders Lund 2013-02-14 17:07:06 UTC
With KDE 4.10, I am back to ONLY having completion of "recent adresses" :-(
Comment 315 Erasmo Caponio 2013-02-14 17:17:57 UTC
(In reply to comment #314)
> With KDE 4.10, I am back to ONLY having completion of "recent adresses" :-(

me too,  on two of the three pc that I use...(all upgraded from kde 4.9.5 to 4.10)
random and very annoying bug
Comment 316 Anders Lund 2013-02-14 17:23:33 UTC
The most silly thing is that disabling nepmuk, completion immediately works flawless.

PLEASE, kmail developers, provide a switch to NOT use nepomuk for completion without having to turn it off.
Comment 317 Andreas Pietzowski 2013-02-14 17:30:25 UTC
...or just fix this 2 year old bug which should be a basic feature for every mail client... :-(

Thanks a lot for fixing this behavior with nepomuk!
Comment 318 regi.hops 2013-02-15 00:08:39 UTC
First of all thanks to all that made KDE 4.10 such a great release.
Especially thanks to Christian and Vishesh for improving nepomuk - great job.

Now what I recognized after upgrading to 4.10 related to this bug:
Just after login to KDE the akonadi_nepomuk_feeder waits approx. 5 minutes to connect to the nepomuk server, and than fails and goes into the state "offline, broken".
If I restart it via "akonadiconsole" it connects and starts indexing immediately.
So I put a small bash-script into my autostart folder, which sleeps around 20 seconds in the background and than restarts the feeder via qdbus command.
This gives me auto-completion on two different boxes.
I use only the Kolab-Addressbook, together with an IMAP-Account that starts offline - and I didn't test with other address books.

With 4.9 auto-completion starts after typing 3 letters, now I need to type at least 4 letters than auto-completion starts.
If the result is cached 1 letter is enough (like before).
Comment 319 Sérgio Basto 2013-02-15 00:27:00 UTC
(In reply to comment #318)
> First of all thanks to all that made KDE 4.10 such a great release.
> Especially thanks to Christian and Vishesh for improving nepomuk - great job.
> 
> Now what I recognized after upgrading to 4.10 related to this bug:
> Just after login to KDE the akonadi_nepomuk_feeder waits approx. 5 minutes
> to connect to the nepomuk server, and than fails and goes into the state
> "offline, broken".
> If I restart it via "akonadiconsole" it connects and starts indexing
> immediately.
> So I put a small bash-script into my autostart folder, which sleeps around
> 20 seconds in the background and than restarts the feeder via qdbus command.

could you share this bash-script ? please ! 

Now, the problem is that I couldn't control indexing , because after some time and reboots we got autocompletion , isn't it ?
Comment 320 Graeme Hewson 2013-02-15 05:33:14 UTC
> With 4.9 auto-completion starts after typing 3 letters, now I need to type
> at least 4 letters than auto-completion starts.
> If the result is cached 1 letter is enough (like before).

This is what I found in comment 295, where I gave steps to reproduce one of the problems. Unfortunately I didn't think to state the length of the name in my address book: 3. So this wasn't due to a timing issue, as stated in comment 312, but the length of the name. I too find that four letters are needed in 4.10 (longer than the name!).
Comment 321 Anders Lund 2013-02-15 07:42:23 UTC
Sure, 4.10 is the best KDE ever. Sure, Nepomuk  is starting to fulfill the promises.

I discovered today, that if I type 4 letters, kmail would start to complete parts of my contacts, and after that complete parts of my contacts after one letter - so probably this area is like it used to be. Not working.

There is a comment above telling that contacts with a certain value in a certain nepomuk data will be completed (ClassName must be "PersonContact" , but in my case that is well below 50% of my contacts. There is no logical variation in my data that makes this easy to understand that I can find.

There is also no way to fix it, it is just broken in a random, chaotic, annoying way.
Comment 322 Christian Mollekopf 2013-02-15 09:29:24 UTC
(In reply to comment #321)
> Sure, 4.10 is the best KDE ever. Sure, Nepomuk  is starting to fulfill the
> promises.
> 
> I discovered today, that if I type 4 letters, kmail would start to complete
> parts of my contacts, and after that complete parts of my contacts after one
> letter 

That's a known limitation of virtuoso (we can't search for less than 4 letters in a performant way). After the search has been executed the results are cached and are completed starting from one letter.

> There is a comment above telling that contacts with a certain value in a
> certain nepomuk data will be completed (ClassName must be "PersonContact" ,
> but in my case that is well below 50% of my contacts. There is no logical
> variation in my data that makes this easy to understand that I can find.
> 
> There is also no way to fix it, it is just broken in a random, chaotic,
> annoying way.

I understand that it is annoying, but it's neither chaotic nor random. I just have to look into it (and I will).
Comment 323 Anders Lund 2013-02-15 09:40:16 UTC
Fredag den 15. februar 2013 09:29:24 skrev du:
> That's a known limitation of virtuoso (we can't search for less than 4
> letters in a performant way). After the search has been executed the
> results are cached and are completed starting from one letter.

So if I add a contact to my addressbook, what happens then?

> > There is also no way to fix it, it is just broken in a random, chaotic,
> > annoying way.
> 
> I understand that it is annoying, but it's neither chaotic nor random. I
> just have to look into it (and I will).

Wonderful :-) 

It just feels chaotic and random, even if it isn't, but I take your word for it when 
you say it's not..
Comment 324 Christian Mollekopf 2013-02-15 10:08:31 UTC
(In reply to comment #323)
> Fredag den 15. februar 2013 09:29:24 skrev du:
> > That's a known limitation of virtuoso (we can't search for less than 4
> > letters in a performant way). After the search has been executed the
> > results are cached and are completed starting from one letter.
> 
> So if I add a contact to my addressbook, what happens then?
> 
That should work I think (from a quick look at it at least).
Comment 325 Anders Lund 2013-02-15 10:11:54 UTC
Fredag den 15. februar 2013 09:29:24 skrev du:
> That's a known limitation of virtuoso (we can't 
search for less than 4
> letters in a performant way). After the search has 
been executed the
> results are cached and are completed starting from 
one letter.

How about creating the cache first time composer is 
started?
Comment 326 Hannes Kuhnert 2013-02-15 10:26:05 UTC
(In reply to comment #325)
> Fredag den 15. februar 2013 09:29:24 skrev du:
> > That's a known limitation of virtuoso (we can't search for less than 4
> > letters in a performant way). After the search has been executed the
> > results are cached and are completed starting from one letter.
>
> How about creating the cache first time composer is 
> started?

We’re talking about a cache just for the results of single searches—nothing that could be done in advance.
Comment 327 Graeme Hewson 2013-02-15 10:36:14 UTC
(In reply to comment #324)
> > So if I add a contact to my addressbook, what happens then?
> > 
> That should work I think (from a quick look at it at least).

As I said in comment 320, it doesn't work (before caching) with a name of three letters in my address book. Even if auto-completion doesn't work here, shouldn't the search be done if I press the Return key after entering the name in the To field of the composer?
Comment 328 Christian Mollekopf 2013-02-15 10:48:36 UTC
(In reply to comment #327)
> (In reply to comment #324)
> > > So if I add a contact to my addressbook, what happens then?
> > > 
> > That should work I think (from a quick look at it at least).
> 
> As I said in comment 320, it doesn't work (before caching) with a name of
> three letters in my address book. Even if auto-completion doesn't work here,
> shouldn't the search be done if I press the Return key after entering the
> name in the To field of the composer?

It's a limitation of virtuoso that we can't run searches of less than 4 characters, so it will just be like that for the moment. Once we ironed out the other problems, we can start looking into a workaround for this.
Comment 329 Christian Mollekopf 2013-02-15 10:57:40 UTC
> There is a comment above telling that contacts with a certain value in a
> certain nepomuk data will be completed (ClassName must be "PersonContact" ,
> but in my case that is well below 50% of my contacts. There is no logical
> variation in my data that makes this easy to understand that I can find.

Are you sure this is true? I couldn't find a query which insists on nco:PersonContact, nco:Contact should be completed as well.
Comment 330 Anders Lund 2013-02-15 11:18:38 UTC
Fredag den 15. februar 2013 10:57:40 skrev du:
> https://bugs.kde.org/show_bug.cgi?id=259949
> 
> --- Comment #329 from Christian Mollekopf <mollekopf@kolabsys.com> ---
> 
> > There is a comment above telling that contacts with a certain value in a
> > certain nepomuk data will be completed (ClassName must be "PersonContact"
> > ,
> > but in my case that is well below 50% of my contacts. There is no logical
> > variation in my data that makes this easy to understand that I can find.
> 
> Are you sure this is true? I couldn't find a query which insists on
> nco:PersonContact, nco:Contact should be completed as well.

Any contact that is not a PersonContact in my addressbooks have ClassName 
Resource, and those are not found.
Comment 331 regi.hops 2013-02-15 21:19:08 UTC
Created attachment 77344 [details]
Srcipts to restart the Feeder after a certain delay

Sergio ask for the script I use to restart ANF, here it is.
It consist of two small bash scripts.
Place both into your personal ~/bin folder and make them executable (in the tar-ball they're not).
1. restartANF.sh
This one is the "starter" which calls the second one and immediately fork to the background.
The convenience way is to use your KDE-Systemsettings and add it as an "Autostart-Script".
But please test before you do so, if it really works.
2. delayRestartANF.sh
This on is called by the first script.
It first checks if the status of ANF is false,  If so it restarts ANF one time, and exits.
You can play around with the sleep value, for me 30 seconds was the best value.

Please be aware I do not check if Nepomuk is enabled or something else, so it may silently fails, depending on your configuration.

You can first execute the "qdbus commands" from delayRestart.sh in a terminal to check if they work on your system.
Don't forget to make backups ;-)

Hope that could help some...
Comment 332 regi.hops 2013-02-16 14:28:53 UTC
Some inconsistencies in the search that I recognized:
I have some contacts with @t-online.de and @e-mail.in.th as the domain part of the email address.
If I type "t" or "e" these contacts are found immediately, even if they were not cached before.
Looks like the "-" in the domain part act as a special character.

Contacts that have a nickname value, were never found with it in the first search.
Only if they were cached through another search, then the nickname is also recognized.

Cheers
Regi
Comment 333 Christian Mollekopf 2013-02-19 09:53:45 UTC
(In reply to comment #285)

> But entering/importing a NEW contact with a website address (or may be other
> fields set) will result in a none "PersonContact".
> You can only enter this information in an already existing contact.
> 

Can you reproduce this on 4.10? I can't and the code looks ok as well. If you can reproduce this please open a separate bugreport and link to this one.

btw. nco:Contact is ok as well, not only nco:PersonContact.
Comment 334 regi.hops 2013-02-19 19:36:28 UTC
(In reply to comment #333)
> (In reply to comment #285)
> 
> > But entering/importing a NEW contact with a website address (or may be other
> > fields set) will result in a none "PersonContact".
> > You can only enter this information in an already existing contact.
> > 
> 
> Can you reproduce this on 4.10? I can't and the code looks ok as well. If
> you can reproduce this please open a separate bugreport and link to this one.
> 
> btw. nco:Contact is ok as well, not only nco:PersonContact.

The specific behavior related to the website address field is gone, I can't reproduce it anymore with 4.10.

And if I have my mentioned script from #Comment 331 running, new contacts and changes are found immediately.
If I start KDE 4.10 without that script, new contacts or changes to contacts are ignored, due to ANF isn't connected to Nepomuk.
Comment 335 Anders Lund 2013-03-06 16:48:44 UTC
No functional autocompletion here, using kde 4.10.1. Some of the contacts not used here does not have middle names, but are still having classname "Nepomuk Resource" when looking at akonadiconsole. Some are "PersonContact"s, but those are not nessecarily found when typing in kmail composer address fields.
Comment 336 Anders Lund 2013-03-06 16:54:20 UTC
Really sorry dunno how that happened :\
Comment 337 Fabian 2013-03-12 18:06:22 UTC
Sorry, I've not time at the moment to read all the 336 comments above. So, perhaps someone has written something similar.
I can see still in KDE 4.10 the annoying behavior, that LDAP results seem to override results from akonadi entries (davcard).
From the first letter I typed I get results from ldap addresses. But akonadi results first appear if there is no match in the ldap directory. This is the average case but sometimes everything work as expected. And in very few cases I'm nearly sure that I've seen akonadi results for half an second before the ldap answers.
For me this looks like there is an synchronization problem between different threads, where each is responsible for collecting addresses different sources. But that's just an unqualified guess...
Comment 338 m.wege 2013-03-12 20:45:40 UTC
@Fabian:
I guess the devs also have problems on going through all comments. Therefor I propose you create a separate bug for this specific problem and make it depend on this bug (click on edit in the "depends on"-section of this bug and add the new bug number). So there is a way to discuss the specific problem without loosing overview and at the same time track it as as part of a larger problem.
Comment 339 Tomás Bautista 2013-03-13 08:32:57 UTC
(In reply to comment #337)

> I can see still in KDE 4.10 the annoying behavior, that LDAP results seem to
> override results from akonadi entries (davcard).

Well... over here I would not use the verb "override". To me what it is happening is that, when completing the addresses, it seems that it is consulting the LDAP server and that they are finally presented first independently of the order selected for presenting them -- I have to search the results from akonadi at the end of the list. I just comment you this in case it could help you.
Comment 340 Eugene Shalygin 2013-04-03 14:33:06 UTC
Copletion was working for me with 4.10.1 and patch from https://projects.kde.org/projects/kde/kdepim/repository/revisions/8c2bf14a2ba463435533c3696c13767d909da545

After upgrade to 4.10.2 it broke again :( No more contacts from address books are shown, only those from recent addresses and from "contact found in your data".
Comment 341 regi.hops 2013-04-06 07:22:26 UTC
In reply to comment #340)
> Copletion was working for me with 4.10.1 and patch from
> https://projects.kde.org/projects/kde/kdepim/repository/revisions/
> 8c2bf14a2ba463435533c3696c13767d909da545
> 
> After upgrade to 4.10.2 it broke again :( No more contacts from address
> books are shown, only those from recent addresses and from "contact found in
> your data".

Can confirm this.
Completion was working - now it's broken again :-(
Although in the debugger of Akonadiconsole the results of the search are shown correctly.
Comment 342 Mathias Homann 2013-04-06 07:27:22 UTC
confirmed... updated my KDE to 4.10.2 and autocompletion's broken again.
openSUSE 12.2 here, KDE packages from opensuse build service.
Comment 343 Erasmo Caponio 2013-04-06 08:19:10 UTC
(In reply to comment #340)
> Copletion was working for me with 4.10.1 and patch from
> https://projects.kde.org/projects/kde/kdepim/repository/revisions/
> 8c2bf14a2ba463435533c3696c13767d909da545
> 
> After upgrade to 4.10.2 it broke again :( No more contacts from address
> books are shown, only those from recent addresses and from "contact found in
> your data".

yes, again broken
Kubuntu 12.10, kde 4.10.2
Comment 344 Richard Homonnai 2013-04-06 10:25:56 UTC
It is broken for me too now - but I am still using 4.10.1 - I think it was an Akonadi update I did the last days.
Comment 345 Anders Lund 2013-04-07 06:54:47 UTC
KDE 4.10.2, chakra linux. Completion gone again, after partially working during kde 4.10.1.
Comment 346 Eugene Shalygin 2013-04-07 16:34:53 UTC
On Gentoo and KDE 4.10.2, downgrade of kde-base/kdepim-common-libs to 4.10.1 restores completion
Comment 347 GK 2013-04-07 18:43:47 UTC
I can confirm that is broken also for Kubuntu 12.04.2 after KDE upgrade to 4.10.2.  It seems all distros with KDE are affected.
Comment 348 Cédric Bellegarde 2013-04-08 09:39:31 UTC
Same here, completion broken even for LDAP contacts...
Comment 349 Eugene Shalygin 2013-04-08 10:26:13 UTC
> On Gentoo and KDE 4.10.2, downgrade of kde-base/kdepim-common-libs to 4.10.1
> restores completion
More specific, reverting of the http://quickgit.kde.org/?p=kdepim.git&a=commit&h=02f5f0214e08f70277df5b314df53e1ceda6b9d9 fixes completion for me.
Comment 350 David Faure 2013-04-08 14:05:47 UTC
Fix coming up.
Comment 351 avlas 2013-04-08 14:24:33 UTC
Great!

Any idea about whether we will have to wait until 4.10.3 or you'll try to backport it to 4.10.2.

That might encourage distributions to release the fix...
Comment 352 David Faure 2013-04-08 16:13:51 UTC
4.10.2 is a released tag, not a branch. I can't change the past.

Bug triagers: please don't use the "depends on" feature, unless these other bugs really *must* be fixed first. This wasn't the case here, so my commit for closing this bug failed with:

" Bug 259949 has 4 unresolved dependencies. They must either be resolved or removed from the "Depends on" field before you can resolve this bug as FIXED. "

I changed that to "blocks" (since some of these bugs will actually have to be retested after my fix)

Here's the commit again:

> Git commit 6a06c57f52a00018d607085efa7570deb91dc707 by David Faure.
> Committed on 08/04/2013 at 17:41.
> Pushed by dfaure into branch 'KDE/4.10'.
> 
> Fix kmail autocompletion from akonadi.
> 
> My commit 02f5f0214e made autocompletion from nepomuk work better, but broke
> completion from akonadi. I kept the "keywords" based code, but now it's only
> used for the special case of nickname-based search (because the nickname shouldn't
> appear in the completion item). For everything else it really doesn't make sense
> to have a search engine (akonadi/nepomuk) on top of a search engine
> (the one inside KCompletion).
> 
> This time I verified that:
> * nepomuk search still works
> * contacts from akonadi work again
> * contact groups from akonadi work (after previous commit)
> * nickname-search in akonadi still doesn't work, but it didn't before. More work
> needed for that one. This is the only reason to keep KMailCompletion around btw,
> everything else would work without it.
> FIXED-IN: 4.10.3
> 
> M  +18   -48   libkdepim/addresseelineedit.cpp
> M  +0    -5    libkdepim/addresseelineedit.h
> M  +3    -1    libkdepim/kmailcompletion.h
> 
> http://commits.kde.org/kdepim/6a06c57f52a00018d607085efa7570deb91dc707
Comment 353 Eugene Shalygin 2013-04-08 17:24:25 UTC
(In reply to comment #352)
4.10.2 plus this changeset works fine. Thanks for the quick fix!
Comment 354 regi.hops 2013-04-08 22:45:10 UTC
(In reply to comment #352)
Thanks for taking care so quickly.
New packages for openSUSE 12.3 x86_64 are right now available... and working ;-)
Comment 355 avlas 2013-04-09 12:24:20 UTC
Also Kubuntu has backported the fix. Great job both upstream and downstream :)
Comment 356 Erasmo Caponio 2013-04-09 15:35:23 UTC
(In reply to comment #355)
> Also Kubuntu has backported the fix. Great job both upstream and downstream
> :)

Installed from Kubuntu Raring repositories, it works!
Thank you!
Moreover it seems that the installation  of the packages related to the fixed kdepim one solves also the huge CPU consumption of the process virtuoso-t (a recurrent problem in kde) that I've noticed in kde 4.10.2.
Comment 357 GK 2013-04-10 21:15:16 UTC
Did you also got the fix for Kubuntu 12.04?  I don't have it... Or I might miss something?
Comment 358 Anders Lund 2013-05-15 21:16:15 UTC
After a short period of working completion, I'm back to no completion except for recent adresses again.

ARRRRRRRRGHHH.

For some reason, akonadi decided to drop some of my contacts. So I dropped and recreated the component from my webdav resource used for calendar and contacts in my owncloud server.

I got my contacts back, but lost completion.
Comment 359 m.wege 2013-05-16 05:02:13 UTC
(In reply to comment #358)
> For some reason, akonadi decided to drop some of my contacts. So I dropped
> and recreated the component from my webdav resource used for calendar and
> contacts in my owncloud server.
For this you might join in this bug 
https://bugs.kde.org/show_bug.cgi?id=318966
Comment 360 Ingo Ratsdorf 2013-05-17 11:56:35 UTC
And the weirdest thing happened today (KDE 4.10.2 (Kubuntu)):

Since autocompletion was only partially working, I decided to completely disable Nepomuk since I don't use it for anything else anyway.

Delete Akonadi-Nepomuk-Feeder from Akonadiconsole (will come back but does not matter).
Deleted Nepomuk Tags from Akonadiconsole
Disabled Akonadi-Nepomuk-Feeder service in KDE Settings->Startup Services.
Switched off all Indexing in KDE Settings->Desktop Search

Restart to be on safe side.

And guess what: I found autocompletion to be fully working!!
Without any Nepomuk or Semantic Desktop etc!
Comment 361 ØysteinG 2013-05-21 19:43:28 UTC
(In reply to comment #360)
> And the weirdest thing happened today (KDE 4.10.2 (Kubuntu)):
> 
> Since autocompletion was only partially working, I decided to completely
> disable Nepomuk since I don't use it for anything else anyway.
> 
> Delete Akonadi-Nepomuk-Feeder from Akonadiconsole (will come back but does
> not matter).
> Deleted Nepomuk Tags from Akonadiconsole
> Disabled Akonadi-Nepomuk-Feeder service in KDE Settings->Startup Services.
> Switched off all Indexing in KDE Settings->Desktop Search
> 
> Restart to be on safe side.
> 
> And guess what: I found autocompletion to be fully working!!
> Without any Nepomuk or Semantic Desktop etc!

I can confirm this on 4.10.3 as well. No restart necessary, I only disabled Nepomuk in KDE Settings as mentioned above. As I am not utilising the semantic desktop this was clearly an advantage to me.
Comment 362 Dimitrios Glentadakis 2013-05-22 04:50:06 UTC
I have the version 4.10.2 now, and after have followed the same instruction, to disable Nepomuk, i have the autocompletion working again!
So, it is ok for me as i dont use nepomuk and semantic desktop me too.
Comment 363 Rigo Wenning 2013-05-24 08:56:46 UTC
I have Version 4.10.3 on OpenSuse now and auto-completion works with nepomuk enabled. But it takes some time for the database to respond, so be patient. It also requires restarting akonadi-nepomuk-feeder via akonadiconsole (several times) and for me two days of patience to index my >10Gb of email.

What you get is not the auto-completion from your addressbook, but an auto-completion for all addresses in your entire email archive. 
While this is fantastic, it needs a visible switch if I want auto-completion to be fast and limited to my addressbook(s)
Comment 364 Anders Lund 2013-05-28 14:53:13 UTC
Today no completion.

Is a stable version of kmail planned?
Comment 365 Rigo Wenning 2013-05-28 15:20:23 UTC
(In reply to comment #364)
open akonadiconsole, restart Akonadi Nepomuk Feeder (probably waiting for nepomukserver to start because of the filewatches) wait for the indexing to be completed, enjoy completion of _all_ email addresses in your data
Comment 366 Anders Lund 2013-05-28 15:38:54 UTC
Tirsdag den 28. maj 2013 15:20:23 skrev du:
> https://bugs.kde.org/show_bug.cgi?id=259949
> 
> --- Comment #365 from Rigo Wenning <rigo@w3.org> ---
> (In reply to comment #364)
> open akonadiconsole, restart Akonadi Nepomuk Feeder (probably waiting for
> nepomukserver to start because of the filewatches) wait for the indexing to
> be completed, enjoy completion of _all_ email addresses in your data

But that is what I do not have to have to do!

AND, my addressbooks *WERE* indexed, a few days ago I HAD working completion. 
Nothing changed, except the *UNSTABLE* kdepim system decided, for no valid 
reason, to not do completion any more.

BWADR!
Comment 367 Rigo Wenning 2013-05-28 15:50:22 UTC
(In reply to comment #366)
reason is probably a race condition between akonadi and nepomuk. I'm not a programmer, just a simple lawyer. I assume that because of the filewatch taking time to get installed and delays the coming up of nepomuk. The akonadi starts too early, doesn't find a functional nepomuk and doesn't try again later. 
So your addressbooks are indexed, but search can't access them because the akonadi-nepomuk bridge that would return the results is still waiting for nepomuk. I think there is an easy fix by just looking for nepomuk again 5 min later or to not start akonadi directly on login but rather only after one starts KDEPIM. This would avoid the race condition. Again, all speculation from my side. This is open source, so if you're a programmer, make a fix and submit. I think the KDEPIM wizards would  be more than happy to have that fix. As long as there is no fix, you have to restart the Akonadi Nepomuk Feeder manually via Akonadiconsole
Comment 368 zless 2013-05-28 15:57:33 UTC
(In reply to comment #367)
> reason is probably a race condition between akonadi and nepomuk. 

Rigo, this was true for me also in *pre* KDE 4.10.3. Nowadays with 4.10.3 Akonadi Nepomuk Feeder starts fine, by itself, with no intervention from me. And to add to the point - address completion works fine also.

What KDE version you have?
Comment 369 Anders Lund 2013-05-28 15:57:35 UTC
I think more that akonadi can not keep track of its own data. Probably, the 
resource dropped the collection and/or item IDs, and other parts of akonadi 
got confused.

This appear to happen regularly with the webdav addressbooks.

However, I'm using kmail here, and expecting it to be able to complete 
addresses from my existing addressbooks, which it can't do in any stable way. 
Maybe it would be more clever to not support webdav addressbooks, if they can 
not be handled correctly, or not use nepomuk as long as it can't be done in a 
stable way. 
:(
Comment 370 Rigo Wenning 2013-05-28 16:05:15 UTC
(In reply to comment #368)
I have  4.10.3 "release 563" from OpenSuse KR10 repositories. And I have very bad experience with Webdav resources and SoGo. So I returned to all local. But I use maildir folders (with huge amounts of email) and nepomuk indexes them. So the filewatches take ages to complete despite cutting edge hardware. This is known, nobody has a fix... Perhaps return to the mbox format like evolution...
Comment 371 Hannes Kuhnert 2013-05-29 08:35:46 UTC
Concerning the handling of large Maildirs I’d like to add: Nepomok isn’t neccessary to break it. Only in the pre-Akonadi era it used to work flawlessly, then even with folders containing tenthousands of e-mails.

Akonadi is something that has obviously never been reasoned seriously in all relevant aspects—at least not before the design decision was made.
Comment 372 Hannes Kuhnert 2013-05-29 08:37:34 UTC
Concerning the handling of large Maildirs I’d like to add: Nepomok isn’t necessary to break it. Only in the pre-Akonadi era it used to work flawlessly, then even with folders containing tenthousands of e-mails.

Akonadi is something that has obviously never been reasoned seriously in all relevant aspects—at least not before the design decision was made.
Comment 373 regi.hops 2013-06-13 05:27:25 UTC
(In reply to comment #367)
> As long as there is no fix, you have to restart the
> Akonadi Nepomuk Feeder manually via Akonadiconsole

Hi, see my comment 331 and the attached script may it will be helpful to you.
Comment 374 klaus.onrails 2013-07-07 20:58:04 UTC
> And guess what: I found autocompletion to be fully working!!
> Without any Nepomuk or Semantic Desktop etc!

Thanks. Did it for me.
Now it says:
"You do not have the semantic desktop system enabled. The following features will not work correctly:
- Recipient auto-completion
- Distribution lists
- Per-contact crypto preferences"
... but auto-complete works :/

Qt: 4.8.4
KDE Development Platform: 4.10.4
KDE Daemon: 4.10.4
Comment 375 Volker Kuhlmann 2013-08-14 04:39:07 UTC
I can confirm that the workaround in comment#360 is working -
openSUSE 12.3, KDE 4.10.5.
Without this, it is not working most of the time, contrary to previous claims to be fixed.

Have not tried workaround in comment#331 - can do without desktop search.
Comment 376 Valter Mura 2013-08-23 22:58:29 UTC
(In reply to comment #374)
> 
> > And guess what: I found autocompletion to be fully working!!
> > Without any Nepomuk or Semantic Desktop etc!
> 
> Thanks. Did it for me.
> Now it says:
> "You do not have the semantic desktop system enabled. The following features
> will not work correctly:
> - Recipient auto-completion
> - Distribution lists
> - Per-contact crypto preferences"
> ... but auto-complete works :/

I can confirm that Autocompletion works for Google Contacts if I disable Nepomuk Indexing in System Settings / Desktop Search, with same warning while composing a new message.

Kubuntu 13.04
KDE/Kmail 4.11
Comment 377 Anders Lund 2013-10-02 20:33:09 UTC
I'm really dissapointed when finding that akonadi still drops my collections. They are reestablisehed, appearently with new akonadi IDs, and then I have to wait for reindexing - I can restart KDE to provoke one, but come on, it's 2013... Related: Korganizer disables my calendars when this happens, as silly - about every time I start korganizer I have to reenable my 3 owncloud calendars before the data is displayed. :(
Comment 378 Tobias Leupold 2013-12-01 14:37:11 UTC
I can confirm the behavior described in Comment #361 for my Gentoo system with kmail 4.11.3. Kmail only uses the recently used addresses for auto-completion whereas the others (stored in the normal Akonadi personal contacts resource) are not considered (but can be selected manually). When disabling Nepomuk completely, it works – without even having to restart Kmail.
Comment 379 Sérgio Basto 2014-03-20 21:18:52 UTC
today , autocomplete forgets adressbook ,  on Fedora 20 updated ( 4.12.3 ) 

worked in first time but stops after that . I got ldap which works, recents address . 

:-/
Comment 380 Sérgio Basto 2014-03-20 23:19:53 UTC
(In reply to comment #379)
> today , autocomplete forgets adressbook ,  on Fedora 20 updated ( 4.12.3 ) 
> 
> worked in first time but stops after that . I got ldap which works, recents
> address . 
> 
> :-/

I enabled desktop search , numinous required , also disable my ldap contacts and seems that autocomplete works again ...
Comment 381 Achim Bohnet 2014-03-24 13:51:01 UTC
KDE 4.13 beta3 & baloo:   Fixed. Address completion uses  Webdav(owncloud), LDAP without problems and is very fast!!  Cool!   Recent addresses and adresses from my all stored mails is listed there too.

THHAANNXXX!!!

Achim
Comment 382 Matt Stevens 2015-02-03 03:26:42 UTC
I can confirm this still exists with kmail 4.14.2
Comment 383 Matt Stevens 2015-02-03 03:29:28 UTC
I omitted the fact I am trying to get this to work for all my gmail accounts with gmail addressbooks in kontact. Shouldn't it work with all address book types?
Comment 384 Martin Steigerwald 2015-04-12 12:35:19 UTC
Hello, thank you for reporting this issue. It has a lot of comments and I find it difficult to draw a conclusion about its current state without reading all of them which is quite a lecture. The only recent report seems to be from Matt. I think only this one is related to KMail from KDEPIM 4.14.

Can you provide a summary of the current status with KMail from KDEPIM 4.14 and Akonadi 1.13 regarding the original issue that KMail does not use all addressbooks for autocompletion?

I am specifically interested in: Does this new version still not use all addressbooks for autocompletion? And if so, any details on the setup. Matt, you say this bug still exists for you. What is your setup?

Please provide the following information:
- Exact version of KMail + Akonadi. Preferably with three numbers for KDEPIM like in 4.14.6 (not just 4.14)
- Does the issue still happen?
- If so: A list of all addressbooks in use including of their types and any special configuration… and…
- … a clear indication of which addressbook contacts are missing from autocompletion

For me autocompletion works very well since KMail 4.14, but I just use only local address book so far.

Please also report anything that is not related to this original issue in a separate bug report. Of course please check for duplicates first. Even do so if its related to autocompletion. Please just use this bug for the original issue of not using all addressbooks for completion. Use separate bug reports for any other issues with autocompletion.

Thank you, Martin
Comment 385 Rigo Wenning 2015-04-12 18:12:52 UTC
WFM with local address book (4.14.6). The indication here seems the gmail account. I tried to use SoGO in the past for address synchronization and got random results which is due to a lacking full synchronization module in KDEPIM. There was a bug somewhere AFAIK. But this is due to the bad connection with the remote content rather than the akonadi - side of things IMHO.
Comment 386 Rigo Wenning 2015-04-12 18:13:17 UTC
WFM with local address book (4.14.6). The indication here seems the gmail account. I tried to use SoGO in the past for address synchronization and got random results which is due to a lacking full synchronization module in KDEPIM. There was a bug somewhere AFAIK. But this is due to the bad connection with the remote content rather than the akonadi - side of things IMHO.
Comment 387 Rigo Wenning 2015-04-12 18:13:40 UTC
WFM with local address book (4.14.6). The indication here seems the gmail account. I tried to use SoGO in the past for address synchronization and got random results which is due to a lacking full synchronization module in KDEPIM. There was a bug somewhere AFAIK. But this is due to the bad connection with the remote content rather than the akonadi - side of things IMHO.
Comment 388 Rigo Wenning 2015-04-12 18:13:47 UTC
WFM with local address book (4.14.6). The indication here seems the gmail account. I tried to use SoGO in the past for address synchronization and got random results which is due to a lacking full synchronization module in KDEPIM. There was a bug somewhere AFAIK. But this is due to the bad connection with the remote content rather than the akonadi - side of things IMHO.
Comment 389 Rigo Wenning 2015-04-12 18:13:55 UTC
WFM with local address book (4.14.6). The indication here seems the gmail account. I tried to use SoGO in the past for address synchronization and got random results which is due to a lacking full synchronization module in KDEPIM. There was a bug somewhere AFAIK. But this is due to the bad connection with the remote content rather than the akonadi - side of things IMHO.
Comment 390 Rigo Wenning 2015-04-12 19:03:22 UTC
Chromium doesn't work with the KDE Bug tracker. Sorry for the noise. With rekonq it shouldn't create 5 comments. Apologies
Comment 391 Erasmo Caponio 2015-04-13 08:14:30 UTC
(In reply to Martin Steigerwald from comment #384)
> Hello, thank you for reporting this issue. It has a lot of comments and I
> find it difficult to draw a conclusion about its current state without
> reading all of them which is quite a lecture. The only recent report seems
> to be from Matt. I think only this one is related to KMail from KDEPIM 4.14.
> 
> Can you provide a summary of the current status with KMail from KDEPIM 4.14
> and Akonadi 1.13 regarding the original issue that KMail does not use all
> addressbooks for autocompletion?
> 
> I am specifically interested in: Does this new version still not use all
> addressbooks for autocompletion? And if so, any details on the setup. Matt,
> you say this bug still exists for you. What is your setup?
> 
> Please provide the following information:
> - Exact version of KMail + Akonadi. Preferably with three numbers for KDEPIM
> like in 4.14.6 (not just 4.14)
> - Does the issue still happen?
> - If so: A list of all addressbooks in use including of their types and any
> special configuration… and…
> - … a clear indication of which addressbook contacts are missing from
> autocompletion
> 
> For me autocompletion works very well since KMail 4.14, but I just use only
> local address book so far.
> 
> Please also report anything that is not related to this original issue in a
> separate bug report. Of course please check for duplicates first. Even do so
> if its related to autocompletion. Please just use this bug for the original
> issue of not using all addressbooks for completion. Use separate bug reports
> for any other issues with autocompletion.
> 
> Thank you, Martin

In Kontact 4.14.2 autocompletion works well for me with google contacts
Comment 392 Vojtěch Zeisek 2015-04-14 08:26:36 UTC
It works for me in 4.14.6 for Google as well as CardDAV, openSUSE.
Comment 393 regi.hops 2015-04-14 17:16:41 UTC
(In reply to Martin Steigerwald from comment #384)
KMail/Kontact 4.14.6, Akonadi 1.13.0, openSUSE 13.2
Works fine with local addressbook and Kolab addressbook.
Comment 394 Andrew Crouthamel 2018-09-26 22:17:19 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days, the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information.

For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please set the bug status as REPORTED so that the KDE team knows that the bug is ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 395 Rigo Wenning 2018-09-27 08:59:39 UTC
I think this bug can be closed. It is really overtaken by events. The issue was tightly linked to the semantic desktop and nepomuk. Those are history. WFM now on OpenSuSE Leap 15 with kontact 5.7.3.
Comment 396 Anders Lund 2018-09-27 10:38:11 UTC
I agree, it should be closed. Something like "obsolete" is missing :)
Comment 397 Kevin Kofler 2018-09-27 10:46:40 UTC
Since this is a bug in old Nepomuk code, I think UNMAINTAINED is probably the most fitting resolution here.