Bug 304647 - CardDav data loss
Summary: CardDav data loss
Status: RESOLVED UNMAINTAINED
Alias: None
Product: Akonadi
Classification: Frameworks and Libraries
Component: DAV Resource (show other bugs)
Version: 4.8
Platform: Ubuntu Linux
: NOR critical
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-06 07:42 UTC by Stefan Kebekus
Modified: 2017-01-07 21:37 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
vcf to reproduce the bug (132 bytes, text/plain)
2013-01-08 21:35 UTC, Daniel Laidig
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Kebekus 2012-08-06 07:42:45 UTC
I imported an address book from an .ics file into an address book that corresponds to a folder on a CardDAV server (server = communigate pro). At first the addresses show up in my address book as expected. When akondi syncs with the CardDAV server, all addresses get deleted, the address book becomes empty.

This is a critical issue for me, because I use kontact for my job, and cannot afford to loose data.

Reproducible: Always

Steps to Reproduce:
1. Open kontact, go to address book
2. Import ics file into CardDAV address book
3. Wait five minutes
Actual Results:  
Address book becomed empty.

Expected Results:  
Addresses should have been added to address book.
Comment 1 Grégory Oestreicher 2012-10-22 19:31:19 UTC
Hi

Do you still have this issue? I've tested right now with KDE 4.9.2 and Akonadi 1.8.0 and everything is working fine.

Cheers,
Grégory
Comment 2 Daniel Laidig 2013-01-08 21:34:48 UTC
I can confirm this bug (or at least something very similar) with KDE 4.9.4. To reproduce this bug, try adding the attached .vcf as a VCF File address book and copy the contact to the ownCloud address book.

The vcf contains a custom entry that contains an underscore which is not allowed in the vcf specification. Kontact seems to ignore this, ownCloud returns an error. After copying the contact to the ownCloud address book it is added to the cache and shows up just fine in KAddressBook for a while. There user does not get any error message at all and probably won't notice the loss of data until it's way too late...

Akonadi Console shows:
AgentBase(akonadi_davgroupware_resource_0): Unable to add item: There was a problem with the request. The item has not been created on the server. An unexpected error (415) occurred while attempting to upload https://[url]/apps/contacts/carddav.php/addressbooks/dani/archiv/uNQJBXZthD.vcf. (415).

It's probably hard to prevent this error in all cases in the first place (and I've also been getting some strange 412 errors that I can't reproduce) but at least the error should be handled in a way that won't lead to unnoticed data loss.
Comment 3 Daniel Laidig 2013-01-08 21:35:36 UTC
Created attachment 76321 [details]
vcf to reproduce the bug
Comment 4 Denis Kurz 2016-09-24 20:39:43 UTC
This bug has only been reported for versions older than KDEPIM 4.14 (at most akonadi-1.3). Can anyone tell if this bug still present?

If noone confirms this bug for a recent version of akonadi (part of KDE Applications 15.08 or later), it gets closed in about three months.
Comment 5 Denis Kurz 2017-01-07 21:37:41 UTC
Just as announced in my last comment, I close this bug. If you encounter it again in a recent version (at least 5.0 aka 15.08), please open a new one unless it already exists. Thank you for all your input.