STR: 1. Install facebook 2. Open 'Social' smart collection Facebook should be part of the pinned apps, it isnt
If I wrap a .then around https://github.com/mozilla-b2g/gaia/blob/master/apps/collection/js/native_info.js#L76 then facebook is displayed the second time I open the smart collection
I did it to avoid the race condition when the user adds an icon to a collection and he tries to open the collection immediately https://github.com/mozilla-b2g/gaia/blob/master/apps/collection/js/view_apps.js#L62 Maybe you can follow the same approach
Talked to Cristian on IRC and he said he will steal this one
Created attachment 8454394 [details] Github pull request Hi mates, it seems that works fine but I have to leave the office right now and I prefer a feedback on time before the Monday's review
Comment on attachment 8454394 [details] Github pull request Seems like it should work fine to me, thanks! (Needs a rebase)
This was working at one point. I'd like to add an integration test for this, which will require mocking the "native info" call from E.me within our test fixtures. Cristian - If you don't get around to it, please leave this bug open to track that work, or spin up another bug to add a test.
It still works but is fairly intermittent, I was reproducing it every time at some point, now I cant reproduce it at all
Can we get a clarification on how intermittent?
(In reply to Dale Harvey (:daleharvey) from comment #8) > It still works but is fairly intermittent, I was reproducing it every time > at some point, now I cant reproduce it at all I wonder if it could be possibly related to server response times? It seems like we're missing the init() call here, so it could be possible that sometimes the server responds fast enough, and sometimes it doesn't?
I can reproduce this issue 100% if I open the Social Smart Collection before installing Facebook (on a freshly flashed Flame). Facebook now is appearing below the pinned app section, even after restarting the phone. However, Facebook will appear with the pinned apps if it is installed before the user opens Social Smart Collection for the first time. Facebook will appear with the pinned apps even after it is deleted if user installed it the first time before opening Social Smart Collections. Resetting the phone though Settings > Device Information allows for the different outcomes. Flame Master BuildID: 20140711040202 Gaia: c47094a26c87ba71a3da4bae54febd0da21f3393 Gecko: 1b1296d00330 Version: 33.0a1 (Master) Firmware Version: v122 User Agent: Mozilla/5.0 (Mobile; rv:33.0) Gecko/33.0 Firefox/33.0
I can reproduce only with OWD user builds, which ship the Social collection pre-installed at about 30%. When the pinning fails, I see this in the log: E/GeckoConsole( 1074): Content JS ERROR at app://collection.gaiamobile.org/gaia_build_defer_synchronize.js:320 in error: evme ERROR NativeInfo error TypeError hope this helps :)
No server issues. Two scenarios: * The synchronization process is performed alone (without opening smart collection), it works fine because the icon is not dirty at this point  * Users open the smart collection immediately while or before synchronization process, so the icon is dirty here  and when the code tries to render the icon, the homeicon was not initialized here  and it fails in line 353 as Amir said in comment 12  https://github.com/mozilla-b2g/gaia/blob/master/apps/collection/js/objects.js#L102  https://github.com/mozilla-b2g/gaia/blob/master/apps/collection/js/objects.js#L265
(In reply to Eric Kramer [:Kramer] from comment #11) > I can reproduce this issue 100% if I open the Social Smart Collection before > installing Facebook (on a freshly flashed Flame). Facebook now is appearing > below the pinned app section, even after restarting the phone. Also reproduced with these STR on 2.0 today's build. Gaia ca022f811bcbbda0f89086094a9e92bb220fea18 Gecko https://hg.mozilla.org/releases/mozilla-aurora/rev/376889ab0e02 BuildID 20140713160202 Version 32.0a2 ro.build.version.incremental=109 ro.build.date=Mon Jun 16 16:51:29 CST 2014 B1TC00011220
Comment on attachment 8454394 [details] Github pull request addressed comments and tested
Comment on attachment 8454394 [details] Github pull request I think this is a good first step. I'm not convinced that we're fully out of the woods on the native info stuff, but I think we can land this initially.
Created attachment 8455211 [details] [review] Part 2 - More native info fixes Some more fixes as I noticed some errors when we had to generate the icon. I'm not convinced this is fully working yet though. Cristian - if you want to include this in your PR you can, or I can finish it up separately.
Comment on attachment 8455211 [details] [review] Part 2 - More native info fixes So it appears that my patch fixes saving when it needs to update the icon, but still does not update the icon. I think it's fine to land as-is, as the icon problems are known and being tracked in another non-blocking bug somewhere. Cristian - what do you think?
Comment on attachment 8455211 [details] [review] Part 2 - More native info fixes I gonna add it to the main pr
added your patch
The icon is not updated although the user does not try to open the smart collection during the synchronization. Obviously it is a different bug thought (In reply to Kevin Grandon :kgrandon from comment #18) > Comment on attachment 8455211 [details] [review] > Part 2 - More native info fixes > > So it appears that my patch fixes saving when it needs to update the icon, > but still does not update the icon. I think it's fine to land as-is, as the > icon problems are known and being tracked in another non-blocking bug > somewhere. > > Cristian - what do you think?
(In reply to Kevin Grandon :kgrandon from comment #16) > I'm not convinced that we're fully out of > the woods on the native info stuff, but I think we can land this initially. I agree. I feel the NativeInfo stuff is prone to errors. It was done very quickly to meet v2.0 FL deadline. Any suggestions on how to make it better are welcome :)
Created attachment 8530131 [details] video This issue has been verified successfully on Flame 2.0 & 2.1 See attachment: Verify_video.MP4 Reproducing rate: 0/3 Reproducing steps: 1.Launch Marketplace. 2.Download and install Facebook. 3.Press Home key and launch Social. ** The Facebook is display in Social smart collection screen Flame2.0 build: Gaia-Rev 8d1e868864c8a8f1e037685f0656d1da70d08c06 Gecko-Rev https://hg.mozilla.org/releases/mozilla-b2g32_v2_0/rev/c756bd8bf3c3 Build-ID 20141127000203 Version 32.0 Flame2.1 build: Gaia-Rev 5372b675e018b6aac97d95ff5db8d4bd16addb9b Gecko-Rev https://hg.mozilla.org/releases/mozilla-b2g34_v2_1/rev/f34377ae402b Build-ID 20141127001201 Version 34.0