[Webkit-unassigned] [Bug 128971] [GTK] webkit 2.3.5 build failure with python 3.3.4

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Sep 15 12:06:56 PDT 2015


https://bugs.webkit.org/show_bug.cgi?id=128971

Alberto Garcia <berto at igalia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #225428|0                           |1
        is obsolete|                            |
 Attachment #261222|                            |review?
              Flags|                            |

--- Comment #19 from Alberto Garcia <berto at igalia.com> ---
Created attachment 261222
  --> https://bugs.webkit.org/attachment.cgi?id=261222&action=review
Patch

(In reply to comment #18)
> Good find Berto. I tested Python 2.7.10 and
> 3.4.2. sys.stdout.encoding returns UTF-8 in both versions. But in
> Patrick's report above, it returns 646 in Python 3.3.4. I am
> presuming the version number is responsible for this difference

Nah, it's not a problem with the Python version, it's the locale of
the build environment:

$ LC_ALL=C python2 ./Source/WebInspectorUI/Scripts/cssmin.py < ./Source/WebCore/xml/XMLViewer.css > /dev/null

$ LC_ALL=C python3 ./Source/WebInspectorUI/Scripts/cssmin.py < ./Source/WebCore/xml/XMLViewer.css > /dev/null
Traceback (most recent call last):
  File "./Source/WebInspectorUI/Scripts/cssmin.py", line 46, in <module>
    sys.stdout.write(cssminify(sys.stdin.read()))
  File "/usr/lib/python3.4/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 642: ordinal not in range(128)

So if the locale is set to ascii, then python 3 expects the standard
input to be ascii, and otherwise it complains.

We can tell people to use UTF-8 for building WebKit, but we can also
force the stdin enconding using this patch.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150915/2eaf2e49/attachment.html>


More information about the webkit-unassigned mailing list