Closed Bug 1180745 Opened 10 years ago Closed 10 years ago

Screenshot error logging is broken

Categories

(Testing :: General, defect)

defect
Not set
normal

Tracking

(firefox42 fixed)

RESOLVED FIXED
mozilla42
Tracking Status
firefox42 --- fixed

People

(Reporter: acomminos, Assigned: acomminos)

Details

Attachments

(1 file)

The string substitution code used in automationutils.py when mochitest screenshotting fails is incorrect (format string parameters are not in a tuple). This causes this error to occur when the test screenshotter fails on try: 15:03:56 INFO - Exception in thread ProcessReader: 15:03:56 INFO - Traceback (most recent call last): 15:03:56 INFO - File "/usr/lib/python2.7/threading.py", line 551, in __bootstrap_inner 15:03:56 INFO - self.run() 15:03:56 INFO - File "/usr/lib/python2.7/threading.py", line 504, in run 15:03:56 INFO - self.__target(*self.__args, **self.__kwargs) 15:03:56 INFO - File "/builds/slave/test/build/venv/local/lib/python2.7/site-packages/mozprocess/processhandler.py", line 920, in _read 15:03:56 INFO - callback(line.rstrip()) 15:03:56 INFO - File "/builds/slave/test/build/venv/local/lib/python2.7/site-packages/mozprocess/processhandler.py", line 840, in __call__ 15:03:56 INFO - e(*args, **kwargs) 15:03:56 INFO - File "/builds/slave/test/build/tests/mochitest/runtests.py", line 2373, in processOutputLine 15:03:56 INFO - message = handler(message) 15:03:56 INFO - File "/builds/slave/test/build/tests/mochitest/runtests.py", line 2517, in dumpScreenOnFail 15:03:56 INFO - self.harness.dumpScreen(self.utilityPath) 15:03:56 INFO - File "/builds/slave/test/build/tests/mochitest/runtests.py", line 1562, in dumpScreen 15:03:56 INFO - dumpScreen(utilityPath) 15:03:56 INFO - File "/builds/slave/test/build/tests/mochitest/automationutils.py", line 312, in dumpScreen 15:03:56 INFO - utility[0], err.strerror) 15:03:56 INFO - TypeError: not enough arguments for format string
Here's a patch that fixes the aforementioned string formatting issue. Thanks!
Attachment #8629995 - Flags: review?(jgriffin)
Comment on attachment 8629995 [details] [diff] [review] Fix logging test screenshotting errors. Review of attachment 8629995 [details] [diff] [review]: ----------------------------------------------------------------- Thanks for the fix!
Attachment #8629995 - Flags: review?(jgriffin) → review+
Keywords: checkin-needed
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla42
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: