Bug 1631821 [wpt PR 23143] - Python 3: Convert text to byte string to support PY2 and PY3, a=testonly
authorziransun <zsun@igalia.com>
Wed, 13 May 2020 04:00:34 +0000
changeset 531042 44b819d83fc8d23ef6521e7f9dcd7e0197faed23
parent 531041 0b99e6631600b7ebb7392a0a93dc7f2744094404
child 531043 3bad7b1c8552ba528bf5a406926edae5416b34a4
push id37435
push userapavel@mozilla.com
push dateWed, 20 May 2020 15:28:23 +0000
treeherdermozilla-central@5415da14ec9a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstestonly
bugs1631821, 23143
milestone78.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1631821 [wpt PR 23143] - Python 3: Convert text to byte string to support PY2 and PY3, a=testonly Automatic update from web-platform-tests Python 3: Convert text to byte string to support PY2 and PY3 (#23143) In Python 2, both text and bytes are str type while in Python 3 they are different types. -- wpt-commits: 370fa3a96c2098edaf1e5304a285be4de5bdd1fc wpt-pr: 23143
testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/firefox.py
--- a/testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/firefox.py
+++ b/testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/firefox.py
@@ -484,17 +484,17 @@ class OutputHandler(object):
                 ignore_missing_leaks=["tab", "gmplugin"],
                 log=self.logger,
                 stack_fixer=self.stack_fixer,
                 scope=self.group_metadata.get("scope"),
                 allowed=self.mozleak_allowed)
 
     def __call__(self, line):
         """Write a line of output from the firefox process to the log"""
-        if "GLib-GObject-CRITICAL" in line:
+        if b"GLib-GObject-CRITICAL" in line:
             return
         if line:
             if not self.setup_ran:
                 self.line_buffer.append(line)
                 return
             data = line.decode("utf8", "replace")
             if self.stack_fixer:
                 data = self.stack_fixer(data)