Closed Bug 938406 Opened 8 years ago Closed 8 years ago

[B2G][Contacts] Unable to access contacts imported from Facebook after rebooting device

Categories

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

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(blocking-b2g:1.3+, firefox27 wontfix, firefox28 fixed, firefox29 fixed, b2g-v1.3 fixed)

RESOLVED FIXED
blocking-b2g 1.3+
Tracking Status
firefox27 --- wontfix
firefox28 --- fixed
firefox29 --- fixed
b2g-v1.3 --- fixed

People

(Reporter: nkot, Assigned: baku)

References

Details

(Keywords: regression)

Attachments

(3 files)

Attached file logcat
Description:
 Unable to access contacts imported from Facebook after device reboot. Before rebooting works OK.

Repro Steps:
1) Updated Buri to BuildID: 20131113040200
2) Open Contacts app
3) Tap gear icon and select Sync Facebook friends
4) Open contact details of any of imported contacts
5) Reboot device
6) Open Contacts 

Actual:
 Unable to access imported from Facebook contact

Expected:
 Able to access imported from Facebook contact

Environmental Variables:
Device: Buri 1.3 
BuildID: 20131113040200
Gaia: 7243b75041c93bc7deb240131748d0b164f3f0b0
Gecko: 7b014f0f3b03
Version: 28.0a1
Firmware Version: 20131104

Repro frequency: 100%
blocking-b2g: --- → 1.3?
QA Contact: sparsons
This issue started to occur on the Buri 1.3 Build ID: 20131030040204

Gaia   162cc9cd7153dcb284e5f54d5598fb27f1ab18aa
SourceStamp 829d7bef8b0a
BuildID 20131030040204
Version 28.0a1


Last working Buri 1.3 Build ID: 20131029040205

Gaia   92c097fd7ac9886f937d9decb0e03ab673deaa1b
SourceStamp 518f5bff0ae4
BuildID 20131029040205
Version 28.0a1
If it's a regression on the Gaia side, then it's likely caused by bug 923637.

Sarah - I need gecko commits on that regression window. Can you include that?
Flags: needinfo?(sparsons)
(In reply to Jason Smith [:jsmith] from comment #2)
> If it's a regression on the Gaia side, then it's likely caused by bug 923637.
> 
> Sarah - I need gecko commits on that regression window. Can you include that?

Although what seems more likely here is this could just be a bug in the Data Store API.
Here it is for the 1.3 10/30 build.

Mercurial-Information: <project name="mozilla-central" path="gecko" remote="hgmozillaorg" revision="829d7bef8b0a"/> 
-->
<project name="gecko.git" path="gecko" remote="mozillaorg" revision="fdbfcf7d24795f482e6969b0f664c53c2b3c2ed9"/>

(In reply to Jason Smith [:jsmith] from comment #2)
> If it's a regression on the Gaia side, then it's likely caused by bug 923637.
> 
> Sarah - I need gecko commits on that regression window. Can you include that?
There are lots of [JavaScript Error: "too much recursion"] errors in the log.  This can be a gaia bug.

Sarah, can you please bisect the gaia range?  Thanks!
(In reply to :Ehsan Akhgari (needinfo? me!) from comment #5)
> There are lots of [JavaScript Error: "too much recursion"] errors in the
> log.  This can be a gaia bug.
> 
> Sarah, can you please bisect the gaia range?  Thanks!

If it's Gaia related, then it's likely bug 923637 causing this. It's the only contacts patch that's data store related with facebook involved.
(In reply to Jason Smith [:jsmith] from comment #6)
> (In reply to :Ehsan Akhgari (needinfo? me!) from comment #5)
> > There are lots of [JavaScript Error: "too much recursion"] errors in the
> > log.  This can be a gaia bug.
> > 
> > Sarah, can you please bisect the gaia range?  Thanks!
> 
> If it's Gaia related, then it's likely bug 923637 causing this. It's the
> only contacts patch that's data store related with facebook involved.

within the target regression range*
Here is the gecko commmit for 1.3 10/29 revision="518f5bff0ae4"
Flags: needinfo?(sparsons)
Checked the gecko push log - there really isn't anything here that looks like a potential cause of this bug.

Adding bug 923637 since it looks like the likely cause right now of this bug.
Blocks: 923637
triage: 1.3+ regression
blocking-b2g: 1.3? → 1.3+
Hi guys,

I cannot repro this. Please could you share by private email (jmcf@tid.es), the details of the account you are using to test?

thanks!
Flags: needinfo?(nkot)
Now I've been able to reproduce. This is clearly a platform issue. 

 navigator.getDataStores(DATASTORE_NAME).then(function success(ds) {
 }, function error(err) {} );

It is not calling the success nor the error CB. Ehsan, please could you have a look at it?

thanks!
Flags: needinfo?(nkot) → needinfo?(ehsan)
Andrea, can you please take a look?  Thanks!
Assignee: nobody → amarchesini
Flags: needinfo?(ehsan)
> I cannot repro this. Please could you share by private email (jmcf@tid.es),
> the details of the account you are using to test?

Can you share this with me too? I don't have a facebook account and I cannot reproduce this issue with mochitests.
I've seen this error once, using Firefox Desktop (with DEBUG=1 option), was generated by another error in the app, somehow the error log is not able to display the real reason.

If I find again will try to go deeper on what's going on.
For what its worth I ran into this today trying to test the patches for bug 924139.
Andrea, can you describe how this part of getDataStoreCreate() is supposed to work?

  http://mxr.mozilla.org/mozilla-central/source/dom/datastore/DataStoreService.js#306

Are we guaranteed to have receiveMessage() called after this?
Flags: needinfo?(amarchesini)
Attached patch patchSplinter Review
Actually, it can happen that receiveMessage is not called! Thanks
Attachment #8343228 - Flags: review?(ehsan)
Flags: needinfo?(amarchesini)
ah... I don't know if this patch fixes this bug. But for sure this patch is needed.
Comment on attachment 8343228 [details] [diff] [review]
patch

Review of attachment 8343228 [details] [diff] [review]:
-----------------------------------------------------------------

Can you add a test for this please?
Attachment #8343228 - Flags: review?(ehsan) → review+
I don't think I can simulate this behaviour with a test. It's a timing issue.
It means that IDB is slower than the request. Hard to say that that code actually runs.
https://hg.mozilla.org/mozilla-central/rev/53a630e3ed5e
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
The problem can still be reproduced on unagi Gecko 0871ff3
Status: RESOLVED → REOPENED
Flags: needinfo?(amarchesini)
Resolution: FIXED → ---
Jose, can you help me to reproduce this issue?
Flags: needinfo?(amarchesini) → needinfo?(jmcf)
Sent a private email with detailed instructions and test account data
Flags: needinfo?(jmcf)
Attached patch patch 2Splinter Review
The first patch was not actually able to sent the event properly.
Attachment #8346079 - Flags: review?(ehsan)
This patch removes an additional space between // and dump(...
I know that is not related to this patch but I hate that space any time I see that code :)
BTW, this patch has been tested on a real device.
Attachment #8346079 - Flags: review?(ehsan) → review+
Keywords: checkin-needed
Blocks: 946778
https://hg.mozilla.org/mozilla-central/rev/0275b5c15174
Status: REOPENED → RESOLVED
Closed: 8 years ago8 years ago
Resolution: --- → FIXED
Hi John,
Could be so kind of uplifting this patch to 1.3 branch? 
Bug 949214 is breacking the smoketest and it seems that will be fixed as soon as this patch lands in that branch.
Thanks a lot!!
Flags: needinfo?(jhford)
Looks like this is a gecko patch.  Ryan, could you please take a look at this?
Flags: needinfo?(jhford) → needinfo?(ryanvm)
You need to log in before you can comment on or make changes to this bug.