Bug 285377 - Calendar and contacts stopped synchronizing
Summary: Calendar and contacts stopped synchronizing
Status: RESOLVED FIXED
Alias: None
Product: libkgapi
Classification: Frameworks and Libraries
Component: calendar (show other bugs)
Version: GIT
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Daniel Vrátil
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-31 10:16 UTC by Martin Höher
Modified: 2011-11-09 21:27 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Höher 2011-10-31 10:16:17 UTC
Version:           GIT (using KDE 4.7.2) 
OS:                Linux

Both, the calendar and contacts agents stopped synchronizing data. The tasks agent still works.

Both agents worked for quite a while. However, some actions seem to cause trouble for them. In the Akonadi configuration, the contacts agent always reports "Removing contact (0%)" while the calendar agent reports "Retrieving list of events (100%)". Additionally, when running "akonadictl restart", I get the following messages:

akonadi_googlecontacts_resource_1(5047) KGoogle::KGoogleAccessManager::nam_replyReceived: Unknown error 404 , Google replied ' "" ' 
akonadi_googlecalendar_resource_0(5046) KGoogle::KGoogleAccessManager::nam_replyReceived: Unknown error 410 , Google replied ' "" ' 

To solve this, I had to completely remove both agents from Akonadi and add them again. Afterward, synchronization worked flawless.

Reproducible: Didn't try

Steps to Reproduce:
I have not explicitly tried to reproduce this. However, I think this already happened in the past for me. There seem to be some actions the agents cannot properly deal with, which cause them to hang in an undefined state.


Expected Results:  
The agents should properly initialize and synchronize. Even if something goes wrong (e.g. the agent actually is not able to delete a contact) this should not cause it to wait forever but simply show a error message to the user and continue with the synchronization.
Comment 1 Daniel Vrátil 2011-10-31 11:53:04 UTC
Thanks for reporting this. The "expected result" you described is a correct behavior. Resources currently ignore any errors that may occur during communication with Google, thus the state information remains unchanged, the request gets stuck in the queue and it all collapses :). I will fix this today or tomorrow.

But I'm also interested in the errors returned by Google. Both errors mean, that the resources are looking for something that no longer exists on Google. I tried to reproduce this errors through various method but didn't succeed. Could you please try to reproduce them? It could be related to removing items from address book or calendar, but as I said, I was always successful.
Comment 2 Martin Höher 2011-11-02 18:10:08 UTC
I tried to reproduce this. However, I was not able to get into the exactly same  situation again. What I did:
- create new dummy contact
- delete it via Web interface and...
- nearly the same time delete it in Kontact
This leaves the agent in the "Deleting contact (100%)" state again. However, after restarting Akonadi the agent resumes normal operation.

I will try to do further testing as soon as I find some time and let you know should I be able to reproduce the error.
Comment 3 Daniel Vrátil 2011-11-09 21:27:32 UTC
Hi and sorry for so late response. 

I have pushed an update which makes all resources to abort current task when an errors occurs (like the one when you are trying to delete a contact which does not exist anymore), so they should not hang in "Doing something" status while actually they are not doing anything.

Feel free to reopen if you should run into the same issue in future.

Fixed in git commit 223160cb17e10b6ab88039a5a83f93be3297826f.