Python 3
John Arbash Meinel
john at arbash-meinel.com
Wed Jun 23 02:02:57 BST 2010
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Martin Pool wrote:
> On 23 June 2010 10:58, Martin Pool <mbp at canonical.com> wrote:
>> Many of these cleanups will improve our code even under 2.x.
>
> On the other hand, Robert's patch has things like
>
> -except locale.Error, e:
> +except locale.Error:
> + e = sys.exc_info()[1]
>
> which is clearly worse, and clearly also the kind of thing that can be
> easily mechanically translated by 2to3. I wouldn't like to see that
> kind of thing merged until we've decided we really want a single
> codebase that works on both with no translation.
>
I thought 2to3 doesn't actually handle that. As it expects you've
written python2.6 compatible code which uses:
except locale.Error as e:
Which we *can't* do for 2.4 or 2.5
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkwhXUEACgkQJdeBCYSNAANqvwCfWw4ZAc8laGir/Hfo90D+WTkE
X6oAoKHgMDd+oWNiw88bQr1Xo8dkfPaQ
=Y84/
-----END PGP SIGNATURE-----
More information about the bazaar
mailing list