Closed
Bug 1389500
Opened 8 years ago
Closed 8 years ago
|mach mochitest --verify| fails: KeyError: 'pop from an empty set'
Categories
(Testing :: Mochitest, defect)
Testing
Mochitest
Tracking
(firefox57 fixed)
RESOLVED
FIXED
mozilla57
Tracking | Status | |
---|---|---|
firefox57 | --- | fixed |
People
(Reporter: gbrown, Assigned: gbrown)
References
Details
Attachments
(1 file, 1 obsolete file)
654 bytes,
patch
|
ahal
:
review+
|
Details | Diff | Splinter Review |
Error running mach:
['mochitest', 'testing/mochitest/tests/Harness_sanity/test_sanity.html', '--verify']
The error occurred in code that was called by the mach command. This is either
a bug in the called code itself or in the way that mach is calling it.
You should consider filing a bug for this issue.
If filing a bug, please include the full output of mach, including this error
message.
The details of the failure are as follows:
KeyError: 'pop from an empty set'
File "/home/gbrown/src/testing/mochitest/mach_commands.py", line 409, in run_mochitest_general
**harness_args)
File "/home/gbrown/src/testing/mochitest/mach_commands.py", line 159, in run_desktop_test
result = mochitest.run_test_harness(parser, options)
File "/home/gbrown/objdirs/firefox/_tests/testing/mochitest/runtests.py", line 2917, in run_test_harness
result = runner.verifyTests(options)
File "/home/gbrown/objdirs/firefox/_tests/testing/mochitest/runtests.py", line 2407, in verifyTests
result = step()
File "/home/gbrown/objdirs/firefox/_tests/testing/mochitest/runtests.py", line 2351, in step2
result = self.runTests(stepOptions)
File "/home/gbrown/objdirs/firefox/_tests/testing/mochitest/runtests.py", line 2468, in runTests
prefs = self.prefs_by_manifest[m].pop()
![]() |
Assignee | |
Comment 1•8 years ago
|
||
In runtests.py, self.prefs_by_manifest is populated in getActiveTests() and
its elements are removed in runTests(). runTests() calls getActiveTests()
so I'd expect that to be safe, but getActiveTests() has an early return when
called more than once:
https://dxr.mozilla.org/mozilla-central/rev/5322c03f4c8587fe526172d3f87160031faa6d75/testing/mochitest/runtests.py#1394
In --verify mode, runTests() is called multiple times. The first call to runTests() succeeds, but the second one fails.
Here's a simple, brute-force fix that works for me; I'm certainly open to alternatives.
Attachment #8896288 -
Flags: review?(ahalberstadt)
Comment 2•8 years ago
|
||
Comment on attachment 8896288 [details] [diff] [review]
save and restore prefs_by_manifest
Review of attachment 8896288 [details] [diff] [review]:
-----------------------------------------------------------------
Instead of pop() let's just do:
prefs = list(self.prefs_by_manifest[m])[0]
Attachment #8896288 -
Flags: review?(ahalberstadt) → review-
![]() |
Assignee | |
Comment 3•8 years ago
|
||
Thanks!
Attachment #8896288 -
Attachment is obsolete: true
Attachment #8896355 -
Flags: review?(ahalberstadt)
Updated•8 years ago
|
Attachment #8896355 -
Flags: review?(ahalberstadt) → review+
Pushed by gbrown@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/28d22d9b12a5
Fix |mochitest --verify| by not popping prefs; r=ahal
![]() |
||
Comment 5•8 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox57:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla57
You need to log in
before you can comment on or make changes to this bug.
Description
•