[IPython-dev] Pasting fix, unicode woes

Fernando Perez fperez.net@gmail....
Wed Sep 8 14:24:42 CDT 2010


Hi Thomas,

On Wed, Sep 8, 2010 at 2:24 AM, Thomas Kluyver <takowl@gmail.com> wrote:
> For information, in making it run on python3, I stripped out one piece of
> code that checks if identifiers are pure ascii:
> http://github.com/takowl/ipython/commit/0636636f5da692f198f3d4cbf3f04fc4e2b131bf#diff-2

yes, though perhaps that one shouldn't be deleted but instead only
turned off in an 'if py3' conditional.  Because in py2x, we do still
have the ascii-only restriction for identifiers.  So it would be good
to leave the code be 2x and 3x correct, even if it costs us a few ugly
'if py2' and 'if py3' statements in a few places (I suspect that will
be inevitable, we'll just have to work on making them as cleanly
organized and isolated as possible).

> This works, at least in my simple tests. Only script characters (not symbols
> and punctuation) can be used as identifiers, but I imagine that this is by
> design.
>
> I've just tested, and the python3 version can handle unicode filenames with
> zero fuss (including tab completion), though I think this is down to Python
> 3 itself rather than anything I can take credit for.

Great news to hear!

BTW, Evan and I just pushed some changes to newkernel, so you can stay
up to date.

Best regards, and many thanks again for taking the lead on the py3
problem for us!

f


More information about the IPython-dev mailing list