[Python-Dev] PEP 414 - Unicode Literals for Python 3

martin at v.loewis.de martin at v.loewis.de
Tue Feb 28 17:47:23 CET 2012


> In the end, that's not particularly relevant, because you don't have to
> run the test suite entirely; when working on small changes, you usually
> re-run the impacted parts of the test suite until everything goes fine;
> on the other hand, 2to3 *has* to run on the entire code base.

Not at all. If you are working on the code, 2to3 only needs to run on
the parts of the code that you changed, since the unmodified parts
will not need to be re-transformed using 2to3.

> So, really, it's a couple of seconds to run a single bunch of tests vs.
> several minutes to run 2to3 on the code base.

Not in my experience. The incremental run-time of 2to3 after a single
change is in the order of fractions of a second.

> And it's not just the test suite: every concrete experiment with the
> library you're porting has a serial dependency on running 2to3.

Therefore, your build process should support incremental changes.
Fortunately, distribute does support this approach.

Regards,
Martin




More information about the Python-Dev mailing list