Monica creating duplicate contacts
Upon creating a new contact through the web client, two contacts are added into the database.
One version appears to be the normal version, and another is a vcard version.
I'm running a self-hosted version of Monica v3.7.0
I'm testing Monica for the first time and have noticed duplicates as well. In my case, I have a Monica CardDAV account configured on my iPhone and the native Contacts app is filling up with duplicates whenever I edit a contact.
+1 : same for me on iOS
I am using the monicahq.com hosted version 3.7.0 and this is happening consistently. I hope this gets noticed as a high priority issue as it makes the service entirely unusable.
Trying to create a new contact from my iPhone using Monica as the default and primary contacts source, the contact is saved in Monica but then duplicated consistently, I believe as other have stated it happens on edit.
- On iPhone: I now have 7 duplicates of the same contact. The original is still present but duplicates get created with the phone type changed from
mobileto"CELL. - On the Monica website the original exits as well as two duplicates.
Noticed this a while ago, and set davx5 on my phone to treat it as read only, thinking this would one day be fixed. I'm surprised it hasn't been for years.
Hi, just started playing around with the software and love the idea but also just noticed this bug. Have 4/5 of the same contacts on my android now (Davx5).
Having the same problem. I get a duplicate contact every time I edit a contact on the web app.
Same problem for me on IOS.
Same problem, every edit I do in the phone creates a new contact on monica (sync with Davx5)
Same here. Android/Davx5
Same problem, using DAVx5 on Android
+1. Same issue, using DAVx5 on Android as well.
Looking at the timeline, I'm wondering if this just started, or has it been an on-going issue for years?
Any update on this?
I have the same problem, first in the self-installed version and also in the cloud version. Unfortunately, this is a really annoying bug that has been open for far too long. Unfortunately, I don't see anyone who has provided a pull request to fix it.
For $90 a year, I expect more support.
I think Monica team is busy building: https://www.officelife.io/
------- Original Message ------- On Saturday, December 10th, 2022 at 6:54 PM, Sven Schneider @.***> wrote:
I have the same problem, first in the self-installed version and also in the cloud version. Unfortunately, this is a really annoying bug that has been open for far too long. Unfortunately, I don't see anyone who has provided a pull request to fix it.
For $90 a year, I expect more support.
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>
That's a pity. Given this issue could lead to data lose, I would've imagined it to be of priority.
I'll give it a go, no promises though.
Never worked with carddav so I don't know what is considered the unique identify. I'm sure I'll find in somewhere...
On Sun, 11 Dec 2022, 06:58 Ryonia Coruscare, @.***> wrote:
That's a pity. Given this issue could lead to data lose, I would've imagined it to be of priority.
— Reply to this email directly, view it on GitHub https://github.com/monicahq/monica/issues/6175#issuecomment-1345466381, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGFVUW2SL5HRWNBH26QKC3WMVUQNANCNFSM5XTDNO5A . You are receiving this because you are subscribed to this thread.Message ID: @.***>
You can find the rfc under https://www.rfc-editor.org/rfc/rfc6352
Small update...
Test case: Add simple contact via web UI (first name, last name, gender only). Sync via carddav. Edit contact and add email (important! will explain later) and save. Two contacts are created.
The \App\Http\Controllers\DAV\Backend\CardDAV\CardDAVBackend::updateCard calls the \App\Services\VCard\ImportVCard service which fetches the existing contact and should update it if the contact exists (it does exist) and then it calls the questionable method \App\Services\VCard\ImportVCard::importGeneralInformation which has an IF at the end.
It seems to me that the IF is there to decide whether to insert a new contact or update the existing one BUT it has an optimization for the update branch to prevent unnecessary updates as far as I can tell. https://github.com/monicahq/monica/blob/a07317f309f25772925436346b4ebb23b6e69b43/app/Services/VCard/ImportVCard.php#L579-L583
The test above will produces equal $contactData (new) and $original (old) because the email is not part of the structure. So the IF will create a new contact (via the CreateContact service) which will get updated (email) in the parent method \App\Services\VCard\ImportVCard::importEntry https://github.com/monicahq/monica/blob/a07317f309f25772925436346b4ebb23b6e69b43/app/Services/VCard/ImportVCard.php#L538-L545
IMHO the IF should just check the $contact and that is what I will be testing.
But I would like @asbiin to comment.
Please fix this as this is preventing me from actually using monica
I've forked Monica and edited ImportVCard.php on my self-hosted version as mentioned by @FranPregernik here: https://github.com/monicahq/monica/issues/6175#issuecomment-1367131522 and it's working beautifully for me. No more duplicate contacts - it actually feels usable now
Edit: I spoke too soon. It's started duplicating again. I'll look again shortly as this is super irritating :)
I've forked Monica and edited
ImportVCard.phpon my self-hosted version as mentioned by @FranPregernik here: https://github.com/monicahq/monica/issues/6175#issuecomment-1367131522 and it's working beautifully for me. No more duplicate contacts - it actually feels usable now
Hey, do you think you could put a PR together for the rest of us to enjoy usable contact syncing?
Thanks.
Edit: I spoke too soon. It's started duplicating again. I'll look again shortly as this is super irritating :)
Hey, any news about this topic? :)
Honestly, as much as this has some nice features, broken contact syncing has pushed me into using my Nextcloud instance for contacts now.
It seems with iOS 17 beta this breaks a lot, because (that's my guess) with new synced contact pictures and posters (which happens in the background) it will create multiple new contacts, and because of this new contacts the sync seems to get triggered again and again. I had 20 contacts of one person. Without fixing it will even worse than before.
hey all, it seems that the contact duplicating might be coming from DAVx5, I unsynced (uncheck and then refresh) the contacts and synced them, and all the duplicates are gone
hey all, it seems that the contact duplicating might be coming from DAVx5, I unsynced (uncheck and then refresh) the contacts and synced them, and all the duplicates are gone
Sounds like you might have had a different issue. The one being tracked has the duplicates on Monica's side. Even if you unsynced with DAVx5, you'd still get the duplicates back with the resync with the issue being tracked here.
hey all, it seems that the contact duplicating might be coming from DAVx5, I unsynced (uncheck and then refresh) the contacts and synced them, and all the duplicates are gone
Sounds like you might have had a different issue. The one being tracked has the duplicates on Monica's side. Even if you unsynced with DAVx5, you'd still get the duplicates back with the resync with the issue being tracked here.
probably, I checked my db and there was only one of every contact. every time DAVx5 resyncs (on every refresh, new duplicates appear locally) I get new duplicates too, hence why it looked like the same issue.
Allgood, am glad you managed to get yours sorted though.
I have the same problem on Android 13 using Davx5 running on tags/v4.0.0.
Currently a workaround is to uncheck the contacts in Davx5and sync. This will delete all contacts on the phone.
Then check contact sync again and sync. This takes a while and will have all contacts back on your phone.
This method has a second duplicate left for some accounts - those with a social media account (e.g. whatsapp or telegram).
I hope we get this solved. I love Monica CRM and want to use it. The main feature for me is the sync with the phone. If this is broken or unreliable I cannot sue this.
After some testing:
Upstream works as expected - when you change things on the phone it seems to work fine.
When changing contacts in monica crm (especially the name) and syncing them a new entry in the phones address book is created and the old one remains, creating a duplicate. Most of the time the duplicate is linked with the old entry, but not all the time.