Bug 203489

Summary: Python 3: Add support in webkitpy.port
Product: WebKit Reporter: Jonathan Bedard <jbedard>
Component: Tools / TestsAssignee: Jonathan Bedard <jbedard>
Status: RESOLVED FIXED    
Severity: Normal CC: aakash_jain, commit-queue, dewei_zhu, ews-watchlist, glenn, slewis, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=184986
Attachments:
Description Flags
Patch
none
Patch
none
Patch for landing none

Description Jonathan Bedard 2019-10-28 09:17:26 PDT
webkitpy.port supports layout tests and API tests, among other things. The factory code is imported all over the place, so this turns out to be a blocker for converting the rest of webkitpy.common.
Comment 1 Jonathan Bedard 2019-10-28 09:23:40 PDT
Created attachment 382077 [details]
Patch
Comment 2 dewei_zhu 2019-10-30 10:35:53 PDT
Comment on attachment 382077 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=382077&action=review

> Tools/Scripts/webkitpy/common/version.py:122
> +            result ^= hash(self[i])

This may not be accurate and easy to create a collision.
For example "1.2.3.4.5" will have the same has as "5.4.3.2.1" if I understand the hash algorithm correctly here.
How about using `hash(self.__str__())` or `hash(str(self))` instead?
Comment 3 Jonathan Bedard 2019-10-30 12:04:34 PDT
Created attachment 382339 [details]
Patch
Comment 4 dewei_zhu 2019-10-30 14:16:51 PDT
Comment on attachment 382339 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=382339&action=review

> Tools/ChangeLog:26
> +        * Scripts/webkitpy/port/config_standalone.py: Ditto

Please update the change description for this line. It was a bug before this change.
Comment 5 Jonathan Bedard 2019-10-30 14:21:00 PDT
Created attachment 382353 [details]
Patch for landing
Comment 6 WebKit Commit Bot 2019-10-30 14:57:04 PDT
Comment on attachment 382353 [details]
Patch for landing

Clearing flags on attachment: 382353

Committed r251808: <https://trac.webkit.org/changeset/251808>
Comment 7 WebKit Commit Bot 2019-10-30 14:57:05 PDT
All reviewed patches have been landed.  Closing bug.
Comment 8 Radar WebKit Bug Importer 2019-10-30 14:58:19 PDT
<rdar://problem/56759792>