Closed Bug 935636 Opened 11 years ago Closed 10 years ago

[contacts][matcher] address in existing contact duplicated if importing same vCard/.vcf file several times

Categories

(Firefox OS Graveyard :: Gaia::Contacts, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(b2g-v1.3T affected)

RESOLVED FIXED
2.0 S4 (20june)
Tracking Status
b2g-v1.3T --- affected

People

(Reporter: aryx, Assigned: mbudzynski)

References

Details

(Whiteboard: burirun1.3-3, 1.3tarakorun2,[p=1,5])

Attachments

(1 file, 1 obsolete file)

Boot2Gecko 1.2.0.0-prerelease 20131104224010 on Keon, update channel 'default' When importing contacts from a .vcf file (vcard 2.1 from Android) several times, the addresses of the contacts get duplicated.
Whiteboard: burirun1.3-3
Whiteboard: burirun1.3-3 → burirun1.3-3, 1.3tarakorun2
Assignee: nobody → mbudzynski
Blocks: 1008972
Comment on attachment 8421036 [details] [review] Link to Github pull-request: https://github.com/mozilla-b2g/gaia/pull/19164 This looks good to me, but can you add a test case that tries to perform a duplicate merge? Thanks!
Attachment #8421036 - Flags: review?(bkelly) → feedback+
Assignee: mbudzynski → mri
Jose Manuel, why did you assign yourself to my bug? Are you writing tests for me :)?
Assignee: mri → mbudzynski
(In reply to Michał Budzyński (:michalbe) from comment #3) > Jose Manuel, why did you assign yourself to my bug? Are you writing tests > for me :)? I thought you were not actively working on this one. Please let me know an ETA or We will steal it. Ah, and please ask me for a review once it is finished
Flags: needinfo?(mbudzynski)
I'm including this bug in the current sprint. @michalbe, could you update with an estimation?
Target Milestone: --- → 2.0 S4 (20june)
Flags: needinfo?(mbudzynski)
Whiteboard: burirun1.3-3, 1.3tarakorun2 → burirun1.3-3, 1.3tarakorun2,[p=1,5]
Somehow this patch doesn't solve the problem anymore, I'm investigating it now.
Oh, so the problem is that when we create new contact using Add contact (not when we import it), then export it to the card and import again, the addresses will duplicate. When we import the contact we don't have from a vcard and then import it again everything works as expected. So this patch solves the issue partially. Working on the first condition now.
Ok, so somehow when importing a contacts from vcard our importer creates an empty 'region' field in the address object, I'm working on smarter way of checking if objects are equal.
Attached file Patch
Attachment #8421036 - Attachment is obsolete: true
Attachment #8437737 - Flags: review?(jmcf)
Comment on attachment 8437737 [details] [review] Patch thanks Michal
Attachment #8437737 - Flags: review?(jmcf) → review+
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: