[webkit-reviews] review granted: [Bug 45791] NRWT fails with UnicodeDecodeError on editing/selection/mixed-editability-10.html : [Attachment 67639] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Sep 14 22:39:28 PDT 2010
Eric Seidel <eric at webkit.org> has granted Mihai Parparita
<mihaip at chromium.org>'s request for review:
Bug 45791: NRWT fails with UnicodeDecodeError on
editing/selection/mixed-editability-10.html
https://bugs.webkit.org/show_bug.cgi?id=45791
Attachment 67639: Patch
https://bugs.webkit.org/attachment.cgi?id=67639&action=review
------- Additional Comments from Eric Seidel <eric at webkit.org>
View in context:
https://bugs.webkit.org/attachment.cgi?id=67639&action=prettypatch
I really need to write some documentation for dealing with unicode vs. byte
arrays in webkitpy.
> WebKitTools/Scripts/webkitpy/layout_tests/port/base.py:162
> + def to_raw_bytes(str):
> + if isinstance(str, unicode):
> + return str.encode('utf-8')
> + return str
I suspect other areas of the code I've assumed that file names were unicode
strings. If that's not a valid assumption across platforms we're going to have
more of these bugs. We may need to make a module-wide fix to this.
> WebKitTools/Scripts/webkitpy/layout_tests/port/base_unittest.py:170
> + # actual input is always a raw string, not unicode).
I would have said "raw bytes" instead of "raw string", but that's a total nit.
> WebKitTools/Scripts/webkitpy/layout_tests/port/base_unittest.py:180
> + # be safe
safe.
More information about the webkit-reviews
mailing list