Closed Bug 1136791 Opened 9 years ago Closed 9 years ago

test_marketplace_packaged_app times out after opening Marketplace, unable to search


(Firefox OS Graveyard :: Gaia::UI Tests, defect)

Gonk (Firefox OS)
Not set


(b2g-v2.2 fixed, b2g-master fixed)

2.2 S7 (6mar)
Tracking Status
b2g-v2.2 --- fixed
b2g-master --- fixed


(Reporter: onelson, Assigned: martijn.martijn)




(Whiteboard: [3.0-Daily-Testing])


(4 files)

Attached file feb25_searchApp.html
Jenkins reported a failure at test_marketplace_packaged_app.TestSearchMarketplaceAndInstallApp in the latest smoke report. The test opens the marketplace app then appears to timeout attempting to locate the search bar. This issue does not reproduce manually, as the UI remains functional: user may tap the search bar and locate apps.

Tracebacks (Consecutive Errors):
Traceback (most recent call last):
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 283, in run
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/gaiatest/tests/functional/marketplace/", line 29, in test_search_and_install_app
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/gaiatest/apps/marketplace/", line 60, in search
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 113, in send_keys
    return self.marionette._send_message('sendKeysToElement', 'ok',, value=typing)
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 36, in _
    return func(*args, **kwargs)
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 615, in _send_message
    "Connection timed out", status=errors.ErrorCodes.TIMEOUT)
TimeoutException: TimeoutException: Connection timed out

Most recent errors/exceptions are:
... [show in html report attached]

Traceback (most recent call last):
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 311, in run
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/gaiatest/", line 996, in tearDown
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 531, in tearDown
    (self.filepath.replace('\\', '\\\\'), self.methodName))
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 1293, in execute_script
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 36, in _
    return func(*args, **kwargs)
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 634, in _send_message
  File "/home/flash/Desktop/oliverthor/git/gaia/tests/python/gaia-ui-tests/.env/local/lib/python2.7/site-packages/marionette_client-0.8.7-py2.7.egg/marionette/", line 663, in _handle_error
    "Malformed packet, expected key 'error' to be a dict: %s" % response)
MarionetteException: MarionetteException: Malformed packet, expected key 'error' to be a dict: {u'message': u'this.curBrowser is null', u'error': u"error occurred while processing 'executeScript"}

Environmental Variables:
Device firmware (base)	L1TC100118D0
Device firmware (date)	25 Feb 2015 01:37:14
Device firmware (incremental)	eng.cltbld.20150225.043702
Device firmware (release)	4.4.2
Device identifier	flame
Gaia date	24 Feb 2015 13:10:44
Gaia revision	f6bfd854fe47
Gecko build	20150225010244
Gecko revision	0a8b3b67715a
Gecko version	39.0a1

Reproducible manually: No

Repro frequency: 2/12

Unsure of regression range as jenkins as somewhat sporadic failures for this test in the b2g.inbound.tinderbox suite:
QA Whiteboard: [QAnalyst-Triage?][fxosqa-auto-backlog?]
Flags: needinfo?(pbylenga)
Whiteboard: [3.0-Daily-Testing]
QA Whiteboard: [QAnalyst-Triage?][fxosqa-auto-backlog?] → [QAnalyst-Triage+][fxosqa-auto-backlog?]
Flags: needinfo?(pbylenga)
Yeah, I've seen that sometimes too. For some I thought there was a gaia Marionette issue there also, I remember vaguely I had a similar issue in bug 1086680, comment 45, but that was when replacing an external website with another one.
Increasing the time.sleep() value here seems to solve the issue:
Assignee: nobody → martijn.martijn
Comment on attachment 8571439 [details] [review]
[gaia] mwargers:packaged_app > mozilla-b2g:master

This makes the test pass locally all the time.

I suspect that the loading Marionette is somehow interfering with the loading of a page when using Wait().
Attachment #8571439 - Flags: review?(npark)
Attachment #8571439 - Flags: review?(npark) → review+
Keywords: checkin-needed
Closed: 9 years ago
Resolution: --- → FIXED
Hi Martijn,

Could you please uplift this patch to v2.2? 
Since 2.2 also has this problem, and I got 20/20 passed when I tried with this solution.
Flags: needinfo?(martijn.martijn)
Ok, I made the v2.2 pull request. However, uplifting is blocked on the redness of Treeherder Try. See for discussion in bug 1151902. James Lal need to be contacted about this.
I think he might misunderstand these pull requests. They are meant to fix test failures in v2.2 for Gaia UI tests, so they should make the Treeherder Try v2.2 at least more green than red.
Flags: needinfo?(martijn.martijn) → needinfo?(ashiue)
Blocks: 1155747
ok, thanks for this info.
Flags: needinfo?(ashiue)
Alison, it seems like v2.2 Treeherder Try is green now. Perhaps the v2.2 pull request can be checked in?
Flags: needinfo?(ashiue)
Flags: needinfo?(ashiue)
Hi Martijn,
Can you help to merge this pull request? The Treeherder Try is green.
Thanks Ryan!
Blocks: 1138809
You need to log in before you can comment on or make changes to this bug.