[NFC][Contacts] Contact cannot updated via NFC more than twice

VERIFIED FIXED in 2.0 S4 (20june)

Status

defect
VERIFIED FIXED
5 years ago
5 years ago

People

(Reporter: ashiue, Assigned: arcturus)

Tracking

unspecified
2.0 S4 (20june)
ARM
Gonk (Firefox OS)
Dependency tree / graph

Firefox Tracking Flags

(blocking-b2g:2.0+, b2g-v2.0 verified, b2g-v2.1 verified)

Details

(Whiteboard: [p=2])

Attachments

(2 attachments)

Gaia      7db23414f2d632f4d00b5023ac1090b6045dc5fd
Gecko     https://hg.mozilla.org/mozilla-central/rev/2619a4def1b9
BuildID   20140522160203
Version   32.0a1

Two phone with NFC

STR:
1. Enable NFC on both phones
2. Add a new contact(user1) on phone A
3. Tap 2 phones to share user1
4. Phone A add email information on user1 
5. Tap 2 phones to share user1 again
6. Phone A add birthday information on user1 
7. Tap 2 phones to share user1 again

Expected result:
user1 on phone B should with both email and birthday information

Actual result:
phone B does not get the 2nd updated information (no birthday)
Besides, after phone B import updated data, could not click the new updated contact to view detail (unless press home button, and bring contact app again)
Summary: [NFC][Contacts] Contact cannot updated via NFC over 2 times → [NFC][Contacts] Contact cannot updated via NFC more than twice
Hi michal, please check what is happened.
blocking-b2g: --- → 2.0?
Flags: needinfo?(mbudzynski)
major issue for new feature.
similar to bug 1015060?
blocking-b2g: 2.0? → 2.0+
(In reply to Wesley Huang [:wesley_huang] from comment #2)
> major issue for new feature.
> similar to bug 1015060?

Different scenarios, I am not sure if they have the same root cause...
Component: NFC → Gaia::Contacts
Assignee: nobody → sergi.mansilla
Sergi is on this now.
Flags: needinfo?(mbudzynski)
I think it's not only NFC thing, it could be related to Bug 1008987. Sergi, can you please take a look there as well?
Flags: needinfo?(sergi.mansilla)
Whiteboard: [p=2]
Target Milestone: --- → 2.0 S4 (20june)
Flags: needinfo?(sergi.mansilla)
Assignee: sergi.mansilla → nobody
Taking the NFC bugs
Assignee: nobody → francisco
Yes,

I still can see the famous output:

E/GeckoConsole( 5197): [JavaScript Error: "TypeError: fb.isFbContact is not a function" {file: "app://communications.gaiamobile.org/contacts/js/views/list.js" line: 1006}]
E/GeckoConsole( 5197): [JavaScript Error: "TypeError: container is undefined" {file: "app://communications.gaiamobile.org/dialer/js/call_log.js" line: 943}]
E/GeckoConsole( 5197): [JavaScript Error: "TypeError: devContact is undefined" {file: "app://communications.gaiamobile.org/shared/js/fb/fb_reader_utils.js" line: 101}]
Interesting bug, divided in two parts:

- First we were missing to load the fb libraries when coming from an activity
- Second the vcard parser, when merges a contact should return the merged contact (with id, this is mandatory for the activity, since then moves the action to that contact id details view) instead of the parsed contact from the vcard.

Attaching patch with unit tests
Posted file Pointer to PR 20389
Attachment #8438772 - Flags: review?(jmcf)
Attachment #8438772 - Flags: feedback?(mbudzynski)
Comment on attachment 8438772 [details] [review]
Pointer to PR 20389

From code perspective I'm ok. But I didn't test it

thanks Francisco
Attachment #8438772 - Flags: review?(jmcf) → review+
Tested the patch on Flame ad it doesn't seem to work - we can share the contact, first update works perfectly, but after this nothing is updated - we get the notification about imported contact, notification about one contact merged, we can access the contact form contact list (and it's automagically opened also by the activity), so it is a progress, but there is no data update at all.
Hi Michal,

I've tried the patch again and it's working for me, perhaps I'm doing something else (or not doing) different, here are my steps to check:

- Phone A (android with nfc or firefox os), contact A with one phone number
- Tap phones with a Firefox OS (Phone B), and send the contact to Phone B
- Edit the contact in Phone A, add an extra phone number
- Tap phones and send the contact to Phone B

Phone B ends with the contact with two phone numbers
Flags: needinfo?(mbudzynski)
Pls try the second time - after updating the phone number add, for instance, a birth date, and try to update the contact for the second time.
Flags: needinfo?(mbudzynski) → needinfo?(francisco)
After talking with Michal, we decided to land the patch and as QA for verification since we are seeing different things.

Also bug 1015060 (not landed yet) could be affecting to our tests.
Flags: needinfo?(francisco)
Landed:

https://github.com/arcturus/gaia/commit/28093eb9cc883e4640faae8d9f2e4dfdd201cd3d
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Verified on
Gaia      2402076e6299ab36f492eab17795478c9d2a7ad7
Gecko     https://hg.mozilla.org/releases/mozilla-aurora/rev/c41d7012974e
BuildID   20140617160202
Version   32.0a2
Status: RESOLVED → VERIFIED
Attachment #8438772 - Flags: feedback?(mbudzynski)
This issue has been verified successfully on Flame 2.1
See attachment: verify_video.MP4
Reproducing rate: 0/5
Flame 2.0 versions:
Gaia-Rev        99e4594c66aa3738d58b0cb44bd885a87a063b6e
Gecko-Rev       https://hg.mozilla.org/releases/mozilla-b2g32_v2_0/rev/f91abc6127d9
Build-ID        20141125000201
Version         32.0
Device-Name     flame
FW-Release      4.4.2
FW-Incremental  eng.cltbld.20141125.035023
FW-Date         Tue Nov 25 03:50:34 EST 2014
Bootloader      L1TC00011880

Flame 2.1 versions:
Gaia-Rev        1bdd49770e2cb7a7321e6202c9bf036ab5d8f200
Gecko-Rev       https://hg.mozilla.org/releases/mozilla-b2g34_v2_1/rev/db893274d9a6
Build-ID        20141125001201
Version         34.0
Device-Name     flame
FW-Release      4.4.2
FW-Incremental  eng.cltbld.20141125.040617
FW-Date         Tue Nov 25 04:06:28 EST 2014
Bootloader      L1TC00011880
This issue has been verified successfully on Flame 2.0
Reproducing rate: 0/5
Flame 2.0 versions:
Gaia-Rev        99e4594c66aa3738d58b0cb44bd885a87a063b6e
Gecko-Rev       https://hg.mozilla.org/releases/mozilla-b2g32_v2_0/rev/f91abc6127d9
Build-ID        20141125000201
Version         32.0
Device-Name     flame
FW-Release      4.4.2
FW-Incremental  eng.cltbld.20141125.035023
FW-Date         Tue Nov 25 03:50:34 EST 2014
Bootloader      L1TC00011880
You need to log in before you can comment on or make changes to this bug.