<p>Input = normal 2.x code; Output = code that runs on both 2.x and 3.x. </p>
<p>That is, tinkering with what 2to3 produces, not what it accepts. </p>
<p>--<br>
Nick Coghlan (via Gmail on Android, so likely to be more terse than usual)</p>
<div class="gmail_quote">On Dec 13, 2011 11:46 PM, &quot;Michael Foord&quot; &lt;<a href="mailto:fuzzyman@voidspace.org.uk">fuzzyman@voidspace.org.uk</a>&gt; wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On 13/12/2011 13:33, Laurence Rowe wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Mon, 12 Dec 2011 22:18:40 +0100, Chris McDonough &lt;<a href="mailto:chrism@plope.com" target="_blank">chrism@plope.com</a>&gt; wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Mon, 2011-12-12 at 09:50 -0500, PJ Eby wrote:<br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
        As someone who ported WebOb and other stuff built on top of it<br>
        to Python<br>
        3 without using &quot;from __future__ import unicode_literals&quot;, I&#39;m<br>
        kinda sad<br>
        that to be using best practice I&#39;ll have to go back and flip<br>
        the<br>
        polarity on everything.<br>
<br>
<br>
Eh?  If you don&#39;t need unicode_literals, what&#39;s the problem?<br>
</blockquote>
<br>
Porting the WebOb code sucked.  It&#39;s only about 5K lines of code but the<br>
porting effort took me about 80 hours.  Some of the problem is certainly<br>
my own idiocy, but some of it is just because straddling code across<br>
Python 2 and Python 3 currently requires that you change lots and lots<br>
of code for suspect benefit.<br>
</blockquote>
<br>
Could this manual work be cut down if there was a version of 2to3 that targeted the subset of the language that is compatible with both 2 and 3? That would seem to avoid most of the drawbacks to the current 2to3 approach.<br>

<br>
</blockquote>
I&#39;m not sure what you mean, but it *reads* as if you mean &quot;a version of 2to3 that only converts code that doesn&#39;t need converting&quot;. Could you clarify?<br>
<br>
Thanks,<br>
<br>
Michael<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Laurence<br>
<br>
______________________________<u></u>_________________<br>
Python-Dev mailing list<br>
<a href="mailto:Python-Dev@python.org" target="_blank">Python-Dev@python.org</a><br>
<a href="http://mail.python.org/mailman/listinfo/python-dev" target="_blank">http://mail.python.org/<u></u>mailman/listinfo/python-dev</a><br>
Unsubscribe: <a href="http://mail.python.org/mailman/options/python-dev/fuzzyman%40voidspace.org.uk" target="_blank">http://mail.python.org/<u></u>mailman/options/python-dev/<u></u>fuzzyman%40voidspace.org.uk</a><br>
<br>
</blockquote>
<br>
<br>
-- <br>
<a href="http://www.voidspace.org.uk/" target="_blank">http://www.voidspace.org.uk/</a><br>
<br>
May you do good and not evil<br>
May you find forgiveness for yourself and forgive others<br>
May you share freely, never taking more than you give.<br>
-- the sqlite blessing <a href="http://www.sqlite.org/different.html" target="_blank">http://www.sqlite.org/<u></u>different.html</a><br>
<br>
______________________________<u></u>_________________<br>
Python-Dev mailing list<br>
<a href="mailto:Python-Dev@python.org" target="_blank">Python-Dev@python.org</a><br>
<a href="http://mail.python.org/mailman/listinfo/python-dev" target="_blank">http://mail.python.org/<u></u>mailman/listinfo/python-dev</a><br>
Unsubscribe: <a href="http://mail.python.org/mailman/options/python-dev/ncoghlan%40gmail.com" target="_blank">http://mail.python.org/<u></u>mailman/options/python-dev/<u></u>ncoghlan%40gmail.com</a><br>
</blockquote></div>