Closed Bug 1414063 Opened 7 years ago Closed 7 years ago

Adjust mochitest and reftest default output timeouts

Categories

(Testing :: General, enhancement)

enhancement
Not set
normal

Tracking

(firefox58 fixed)

RESOLVED FIXED
mozilla58
Tracking Status
firefox58 --- fixed

People

(Reporter: gbrown, Assigned: gbrown)

References

Details

Attachments

(1 file, 1 obsolete file)

This is a follow-up to https://bugzilla.mozilla.org/show_bug.cgi?id=1397201#c64. In browser tests, under normal conditions: - We want the js test harness to detect and handle normal test hangs. - We want marionette to detect and handle hangs on a marionette socket operation. - If a test still does not produce output despite those safeguards, we want the python test harness to time out. Currently the js mochitest and reftest timeouts are 300 seconds: https://dxr.mozilla.org/mozilla-central/source/testing/mochitest/tests/SimpleTest/TestRunner.js#91 https://dxr.mozilla.org/mozilla-central/rev/b5a3b8ef6902998507fc881b6d628b055457fe31/layout/tools/reftest/reftestcommandline.py#74 Currently the default marionette socket timeout is 360 seconds: https://dxr.mozilla.org/mozilla-central/rev/b5a3b8ef6902998507fc881b6d628b055457fe31/testing/marionette/client/marionette_driver/marionette.py#562 Currently the default python mochitest and reftest timeouts are 330 seconds: https://dxr.mozilla.org/mozilla-central/rev/b5a3b8ef6902998507fc881b6d628b055457fe31/testing/mochitest/runtests.py#2655 https://dxr.mozilla.org/mozilla-central/rev/b5a3b8ef6902998507fc881b6d628b055457fe31/layout/tools/reftest/runreftest.py#801 Let's change the default python timeouts to > 360 seconds.
Comment on attachment 8924747 [details] [diff] [review] increase default mochitest/reftest python harness output timeout to 370 seconds Review of attachment 8924747 [details] [diff] [review]: ----------------------------------------------------------------- do we have to worry about android in a different fashion? What about mozharness- does it have a timeout on the output handler? ::: layout/tools/reftest/runreftest.py @@ +797,5 @@ > + # The default Marionette socket timeout is currently 360 seconds. > + # Wait a little (10 seconds) more before timing out here. > + timeout = options.timeout + 30.0 > + if timeout < 360: > + timeout = 370 assuming we set options.timeout, this would be confusing for people- can you output a warning message to inform the end user? Also who really uses options.timeout?
Attachment #8924747 - Flags: review?(jmaher) → review-
In my try push, there is at least one "370 seconds without output": https://treeherder.mozilla.org/logviewer.html#?job_id=141822444&repo=try ...so maybe this won't help bug 1397201?
if we got to 370, does that mean that marionette completed?
(In reply to Joel Maher ( :jmaher) (UTC-5) from comment #2) > What about > mozharness- does it have a timeout on the output handler? mozharness typically runs the test harness with an output timeout of 1000 seconds. https://treeherder.mozilla.org/logviewer.html#?job_id=141822444&repo=try&lineNumber=1941 22:53:35 INFO - Calling ['Z:\\task_1509661616\\build\\venv\\Scripts\\python', '-u', 'Z:\\task_1509661616\\build\\tests\\mochitest\\runtests.py', '--total-chunks', '8', '--this-chunk', '1', '--appname=Z:\\task_1509661616\\build\\application\\firefox\\firefox.exe', '--utility-path=tests/bin', '--extra-profile-file=tests/bin/plugins', '--symbols-path=Z:\\task_1509661616\\build\\symbols', '--certificate-path=tests/certs', '--quiet', '--log-raw=Z:\\task_1509661616\\build\\blobber_upload_dir\\mochitest-devtools-chrome-chunked_raw.log', '--log-errorsummary=Z:\\task_1509661616\\build\\blobber_upload_dir\\mochitest-devtools-chrome-chunked_errorsummary.log', '--screenshot-on-fail', '--cleanup-crashes', '--marionette-startup-timeout=180', '--flavor=browser', '--subsuite=devtools', '--chunk-by-runtime'] with output_timeout 1000
(In reply to Joel Maher ( :jmaher) (UTC-5) from comment #2) > do we have to worry about android in a different fashion? I think Android is okay. Android mochitests and Android opt reftests use the same timeout as desktop. Android debug reftests set options.timeout to 600. (Also, Android mochitests and reftests don't use marionette.)
(In reply to Geoff Brown [:gbrown] from comment #5) > (In reply to Joel Maher ( :jmaher) (UTC-5) from comment #2) > > What about > > mozharness- does it have a timeout on the output handler? > > mozharness typically runs the test harness with an output timeout of 1000 > seconds. So when mozharness typically uses 1000s for output timeout, why are mochitests run with 330s? Looks like we miss to specify the 1000s, or do not correctly forward this value to the mochitest harness?
Flags: needinfo?(gbrown)
We don't forward the mozharness output timeout to the mochitest harness. I've always thought of them as separate, with one as a backup for the other: If the mochitest harness correctly times out, the mozharness timeout is never hit; if the mochitest harness somehow fails to time out and complete, the mozharness timeout should still work.
Flags: needinfo?(gbrown)
Comment on attachment 8924747 [details] [diff] [review] increase default mochitest/reftest python harness output timeout to 370 seconds Review of attachment 8924747 [details] [diff] [review]: ----------------------------------------------------------------- I would leave this review for Joel given that he has better knowledge about both harnesses.
Attachment #8924747 - Flags: review?(hskupin)
This is hard to make pretty, but here's a slightly different way of getting to the same place in most cases. Better? (Regardless of the structures and details, keep in mind that try pushes indicate this will not reduce timeouts, nor improve diagnostics on timeout. On the other hand, it seems logical to keep the harness output timeout > the marionette socket timeout.)
Attachment #8924747 - Attachment is obsolete: true
Attachment #8925106 - Flags: review?(jmaher)
I also changed "5 * 60" to "300" since that's what I always search for and can't find!
Comment on attachment 8925106 [details] [diff] [review] increase default mochitest/reftest python harness output timeout to 370 seconds Review of attachment 8925106 [details] [diff] [review]: ----------------------------------------------------------------- lets go with it
Attachment #8925106 - Flags: review?(jmaher) → review+
Pushed by gbrown@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/1efa6f4269ca Increase mochitest/reftest default output timeout to 370 seconds; r=jmaher
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: