Bug 1183719

Summary: "FOREIGN KEY constraint failed" trying to delete contact
Product: [Fedora] Fedora Reporter: Tim Waugh <twaugh>
Component: evolutionAssignee: Milan Crha <mcrha>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 21CC: lucilanga, mbarnes, mcrha, paul, tpopela
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: evolution-data-server-3.12.11-2.fc21 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-04 15:14:56 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tim Waugh 2015-01-19 15:09:43 UTC
Description of problem:
Trying to delete a contact gives the error message "FOREIGN KEY constraint failed". The contact remains in the address book.

Version-Release number of selected component (if applicable):
evolution-data-server-3.12.9-2.fc21.x86_64
evolution-3.12.9-1.fc21.x86_64

How reproducible:
100% for me

Steps to Reproduce:
1.Go to Contacts, On This Computer, Personal
1.Click on a contact
2.Click Delete icon
3.Confirm

Actual results:
Error message.

Comment 1 Paul Finnigan 2015-01-22 16:39:15 UTC
I had the same problem with 87 of ~200 contacts!

I have two systems. One upgraded with fedup. That has no problem (that I know of) with contacts. I have tried to delete a few and it worked fine.

The other system was a fresh build. I backed up evolution with the built in option on fedora 20, restoring it on the newly built fedora 21. On this system I had problems syncing with funambol using syncevolution. I also got the delete problem when deleting a contact that I had duplicated. I then tried to delete ALL my contacts, that is how I know that 87 of the ~200 contacts were effected.

I managed to fix the problem by renaming directory ~/.local/share/evolution/addressbook/system/ to ~/.local/share/evolution/addressbook/system.bak/ and restarted my system.

I was then able to sync using syncevolution (after a couple of hiccups).

I am not suggesting that this is a fix. I am just trying to highlight what I went through to overcome what appears to be a bug.

Comment 2 Milan Crha 2015-02-04 15:14:56 UTC
Thanks for a bug report. I moved this upstream as [1]. Please see [1] for any further updates. If possible, please CC yourself there, in case upstream developers will have additional questions.

[1] https://bugzilla.gnome.org/show_bug.cgi?id=743996

Comment 3 Fedora Update System 2015-04-14 10:36:26 UTC
evolution-data-server-3.12.11-2.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/evolution-data-server-3.12.11-2.fc21

Comment 4 Fedora Update System 2015-05-08 07:36:36 UTC
evolution-data-server-3.12.11-2.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.