[anaconda][master][Python 3][PATCH 0/2] Two more steps towards Python 3
David Shea
dshea at redhat.com
Fri Jun 27 13:37:25 UTC 2014
On 06/27/2014 09:17 AM, Martin Kolman wrote:
> The first patch makes our use of the reduce function Python 3 compatible
> (yes, we DO use reduce!) and the second patch makes the next() generator calls
> Python compatible.
>
> I've done some simple Python 3 compatibility scanning by running the Anaconda
> source through python3 -m compileall and 2to3 (lives in python-tools BTW).
> From the output it looks like that most of the stuff that can be easily
> changed to work in both 2 & 3 without special compatibility machinery has
> been already done.
>
> The remaining changes are what I would call "flag day changes" as they
> either can degrade performance in Python 2 (using items() in place of iteritems(), etc.)
> or are outright Python 2 incompatible without additional Python 3 compatibility machinery
> (mostly standard library module renames and reorganizations).
>
> As I don't think maintaining compatibility with Python 2 is needed once Anaconda
> works with Python 3 (unlike for Pykickstart & Blivet),so the remaining changes should
> be done once the Python 3 "flag day" comes without regard for Python 2 compatibility.
>
> Martin Kolman (2):
> Make reduce function usage Python 3 compatible
> Use the built-in next() function for generators
>
> pyanaconda/addons.py | 5 +++--
> pyanaconda/anaconda_argparse.py | 2 +-
> pyanaconda/bootloader.py | 2 +-
> pyanaconda/ui/gui/hubs/progress.py | 2 +-
> pyanaconda/ui/tui/simpleline/base.py | 3 ++-
> scripts/anaconda-yum | 4 ++--
> 6 files changed, 10 insertions(+), 8 deletions(-)
>
These both look good.
More information about the anaconda-patches
mailing list