[Python-Dev] readd u'' literal support in 3.3?

Stefan Behnel stefan_ml at behnel.de
Wed Dec 14 19:05:54 CET 2011

"Martin v. Löwis", 14.12.2011 18:23:
>> overhead of running 2to3 every time 'setup.py develop' etc. runs dooms
>> the effort.
> How so? Running 2to3 after every change is very fast. I never use
> setup.py develop, though.

I think the problem starts with the fact that it needs to be run in the 
first place. It's not enough any more to just fire up the interpreter and 
run a test, you first have to build your code before you can get back to 
work, and it gets moved away into a separate directory and runs from there. 
So your workspace looks different depending on the environment you are 
currently testing with, and all your development tools have to support that 
as well.

Even if the build step does not take half an hour, it's an otherwise 
unnecessary step that makes working and testing with Python 3 substantially 
less comfortable, and thus less likely to happen. And we all know where a 
reluctance against testing leads us.

And, just for the record, we use 2to3 for Cython's code base, and I'm not 
convinced that this was a good decision. Testing the code in Py3 is 
actually something that I avoid if not strictly necessary, and that I leave 
to our CI server in most cases.

I'm much more happy with lxml which was ported before there even was a 
2to3, so it works on 2 and 3 out of the box. That alone makes it much nicer 
to develop on, and I think that it was clearly worth the additional porting 
work at the time.


More information about the Python-Dev mailing list