Bug 105742 - Make the override-feature-defines script compatible with Python v3
Summary: Make the override-feature-defines script compatible with Python v3
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Zan Dobersek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-25 10:20 PST by Zan Dobersek
Modified: 2013-01-08 09:34 PST (History)
1 user (show)

See Also:


Attachments
Patch (1.42 KB, patch)
2012-12-25 10:22 PST, Zan Dobersek
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Zan Dobersek 2012-12-25 10:20:18 PST
Make the override-feature-defines script compatible with Python v3
Comment 1 Zan Dobersek 2012-12-25 10:22:42 PST
Created attachment 180713 [details]
Patch
Comment 2 Eric Seidel (no email) 2012-12-26 17:54:43 PST
Comment on attachment 180713 [details]
Patch

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

> Tools/gtk/override-feature-defines:33
> +        print("The following feature defines were overriden:\n{0}".format(', '.join(overriden_feature_defines)))

Has the % operator been removed from py3?
Comment 3 Zan Dobersek 2012-12-27 00:20:38 PST
(In reply to comment #2)
> (From update of attachment 180713 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=180713&action=review
> 
> > Tools/gtk/override-feature-defines:33
> > +        print("The following feature defines were overriden:\n{0}".format(', '.join(overriden_feature_defines)))
> 
> Has the % operator been removed from py3?

Not yet, but there were plans to deprecate and eventually remove it[1]. The plans might have changed since then, though[2]. The Advances String Formatting[3], supported since Python 2.6, is recommended (especially in Python 3).


[1] http://docs.python.org/release/3.2.3/whatsnew/3.0.html#pep-3101-a-new-approach-to-string-formatting
[2] http://www.mail-archive.com/django-developers@googlegroups.com/msg35057.html
[3] http://www.python.org/dev/peps/pep-3101/
Comment 4 Zan Dobersek 2013-01-08 09:34:15 PST
Comment on attachment 180713 [details]
Patch

Clearing flags on attachment: 180713

Committed r139065: <http://trac.webkit.org/changeset/139065>
Comment 5 Zan Dobersek 2013-01-08 09:34:22 PST
All reviewed patches have been landed.  Closing bug.