Closed
Bug 1202576
Opened 9 years ago
Closed 9 years ago
Hang in test_about_private_browsing.py (testCheckAboutPrivateBrowsing) if element cannot be found in a different chrome window
Categories
(Testing :: Firefox UI Tests, defect)
Tracking
(firefox43 wontfix, firefox44 wontfix, firefox45 fixed, firefox46 fixed, firefox-esr38 wontfix)
People
(Reporter: whimboo, Unassigned)
References
Details
(Keywords: hang, Whiteboard: [failure])
Seen today for functional tests of the Firefox 41.0b8 ar locale:
https://treeherder.mozilla.org/logviewer.html#?job_id=502371&repo=mozilla-beta
Whenever the referenced element 'learnMore' is not found the test hangs forever and Marionette does not kill the run even not after the global timeout. This might be a Marionette bug but would need some more investigation first.
To reproduce the problem do the following steps:
1. Clone https://github.com/mozilla/firefox-ui-tests
2. Open firefox_ui_tests/functional/private_browsing/test_about_private_browsing.py in your editor
3. Change the element 'learnMore' to 'learnMor'
4. Save and run this single test via 'firefox-ui-tests --binary Nightly firefox_ui_tests/functional/private_browsing/test_about_private_browsing.py'
This problem is causing bustage on our CI machines because Jenkins kills those builds but Marionette leaves Firefox instances behind. See bug 1201871. So the machine becomes unusable until all remaining Firefox and Python processes get killed manually.
Comment hidden (Legacy TBPL/Treeherder Robot) |
Reporter | ||
Comment 2•9 years ago
|
||
Here the Marionette logging output:
1441698486615 Marionette DEBUG conn3 -> ({"name":"getChromeWindowHandles"})
1441698486616 Marionette DEBUG conn3 client <- ({"from":"0","value":["3","15"],"status":"success","sessionId":"27926ea2-b2cd-428b-99a8-ba592405c757"})
1441698486616 Marionette DEBUG conn3 -> ({"name":"getChromeWindowHandles"})
1441698486617 Marionette DEBUG conn3 client <- ({"from":"0","value":["3","15"],"status":"success","sessionId":"27926ea2-b2cd-428b-99a8-ba592405c757"})
1441698486617 Marionette DEBUG conn3 -> ({"name":"findElement","parameters":{"using":"id","value":"menu_closeWindow"}})
1441698486618 Marionette DEBUG conn3 client <- ({"from":"0","value":{"ELEMENT":"c921d6d2-85be-40d1-b39f-c3e6f5a4aada"},"status":"success","sessionId":"27926ea2-b2cd-428b-99a8-ba592405c757"})
1441698486619 Marionette DEBUG conn3 -> ({"name":"clickElement","parameters":{"id":"c921d6d2-85be-40d1-b39f-c3e6f5a4aada"}})
1441698486621 Marionette DEBUG conn3 client <- ({"from":"0","ok":true})
1441698486679 Marionette DEBUG conn3 -> ({"name":"getChromeWindowHandles"})
1441698486679 Marionette DEBUG conn3 client <- ({"from":"0","value":["3"],"status":"success","sessionId":"27926ea2-b2cd-428b-99a8-ba592405c757"})
1441698486681 Marionette DEBUG conn3 -> ({"name":"getContext"})
1441698486681 Marionette DEBUG conn3 client <- ({"from":"0","value":"chrome","status":"success","sessionId":"27926ea2-b2cd-428b-99a8-ba592405c757"})
1441698486682 Marionette DEBUG conn3 -> ({"name":"setContext","parameters":{"value":"chrome"}})
1441698486682 Marionette DEBUG conn3 client <- ({"from":"0","ok":true})
1441698486687 Marionette DEBUG conn3 -> ({"name":"takeScreenshot","parameters":{"highlights":null,"full":true,"id":null}})
Looks like the problem here is inside the takeScreenshot call which does not return. I will dig deeper.
Reporter | ||
Comment 3•9 years ago
|
||
It is actually bug 1141519 which is causing this problem for us. Reason is that an exception gets thrown in content scope.
Depends on: 1141519
Whiteboard: [failure] → [failure][blocked]
Comment hidden (Legacy TBPL/Treeherder Robot) |
Comment hidden (Legacy TBPL/Treeherder Robot) |
Reporter | ||
Comment 6•9 years ago
|
||
So the hang in screenshot is affecting us actually on all branches. So we have to wait for the fix on bug 1202663, which Andreas wants to continue on today.
status-firefox41:
--- → affected
status-firefox42:
--- → affected
status-firefox44:
--- → affected
status-firefox-esr38:
--- → affected
Comment hidden (Legacy TBPL/Treeherder Robot) |
Comment hidden (Legacy TBPL/Treeherder Robot) |
Comment hidden (Legacy TBPL/Treeherder Robot) |
Reporter | ||
Comment 10•9 years ago
|
||
The upgrade to marionette client and driver will not fix that. We have to wait for another release and bug 1202663 being fixed.
Reporter | ||
Comment 11•9 years ago
|
||
It's still not working yet with latest Nightly builds. Currently I get the failure as logged as bug 1215502. Maybe that is still causing the hang? When I check the log I do not see a response from takeScreenshot:
1445252519738 Marionette DEBUG conn3 -> {"name":"setContext","parameters":{"value":"chrome"}}
1445252519738 Marionette DEBUG conn3 client <- {}
1445252519739 Marionette DEBUG conn3 -> {"name":"takeScreenshot","parameters":{"highlights":null,"full":true,"id":null}}
*************************
A coding exception was thrown in a Promise rejection callback.
See https://developer.mozilla.org/Mozilla/JavaScript_code_modules/Promise.jsm/Promise
Full message: TypeError: 'toString' called on an object that does not implement interface Exception.
Full stack: error.isError@chrome://marionette/content/error.js:78:12
error.isWebDriverError@chrome://marionette/content/error.js:86:10
Flags: needinfo?(ato)
Comment 12•9 years ago
|
||
Has this been resolved now that bug 1202663 has landed? I also looked into bug 1215502, and error.toJSON has since been removed.
Flags: needinfo?(ato)
Reporter | ||
Comment 13•9 years ago
|
||
We still seem to hang here with the latest released marionette client and driver:
File "/home/henrik/.virtualenvs/fxtests/local/lib/python2.7/site-packages/marionette_driver-1.1.1-py2.7.egg/marionette_driver/marionette.py", line 718, in _send_message
raise IOError("process died with returncode %s" % returncode)
IOError: process died with returncode None
When I explicitly break the execution via Ctrl-C I see the following:
rv['screenshot'] = marionette.screenshot()
File "/home/henrik/.virtualenvs/fxtests/local/lib/python2.7/site-packages/marionette_driver-1.1.1-py2.7.egg/marionette_driver/marionette.py", line 1957, in screenshot
data = self._send_message("takeScreenshot", body, key="value")
File "/home/henrik/.virtualenvs/fxtests/local/lib/python2.7/site-packages/marionette_driver-1.1.1-py2.7.egg/marionette_driver/decorators.py", line 36, in _
return func(*args, **kwargs)
File "/home/henrik/.virtualenvs/fxtests/local/lib/python2.7/site-packages/marionette_driver-1.1.1-py2.7.egg/marionette_driver/marionette.py", line 708, in _send_message
msg = self.client.receive()
File "/home/henrik/.virtualenvs/fxtests/local/lib/python2.7/site-packages/marionette_transport-1.0.0-py2.7.egg/marionette_transport/transport.py", line 178, in receive
chunk = self.sock.recv(bytes_to_recv)
So we still hang in taking the screenshot, right?
Flags: needinfo?(ato)
Reporter | ||
Comment 14•9 years ago
|
||
Hm, maybe the JS error as logged as bug 1215502 is causing this hang?
Assignee | ||
Updated•9 years ago
|
Product: Mozilla QA → Testing
Comment 15•9 years ago
|
||
Yes, this is caused by bug 1215502.
Depends on: 1215502
Flags: needinfo?(ato)
Whiteboard: [failure][blocked by bug 1202663] → [failure][blocked by bug 1215502]
Reporter | ||
Comment 16•9 years ago
|
||
The fix for bug 1215502 made this hang disappear! I hope that we can also get it backported to 45 which will be our next ESR branch.
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox41:
affected → ---
status-firefox42:
affected → ---
status-firefox45:
--- → affected
status-firefox46:
--- → fixed
No longer depends on: 1238996
Resolution: --- → FIXED
Whiteboard: [failure][blocked by bug 1215502] → [failure]
Reporter | ||
Comment 17•9 years ago
|
||
The patch did also land on mozilla-aurora. So all cleared for the ESR branch.
You need to log in
before you can comment on or make changes to this bug.
Description
•