Terry J. Reedy <[email protected]> added the comment:
Interesting -- and nasty. I have used this successfully with both 3.2 and now
3.3 on Win7 to search idlelib/*.py files and on a directory of my own files,
all written by Idle and been quite pleased with the speed.
I just tried searching /Lib/*.py for 'itertools' and quickly got 10 results (up
to decimal.py) before Idle disappeared. OK, import idlelib/idle in console,
repeat, and I get the same traceback up to
File "C:\Programs\Python33\lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 1877:
character maps to <undefined>
This is not a problem on 2.7.
Patch fixes problem, so I committed it so it will be in 3.3.0a4 (in a few days).
The default extension is .py. The default encoding for .py files is utf-8. I
think that is the default for what Idle writes. So I think this should be the
default encoding (explicitly given) at least for .py files.
----------
assignee: -> terry.reedy
versions: +Python 3.3
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue14929>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com