Anything like 'inspect.getsourceencoding()'?
Jeff Epler
jepler at unpythonic.net
Sat Oct 16 22:14:34 EDT 2004
Is there a convenient way to find the encoding of a source file? I
thought maybe this would be in the inspect module, but I didn't see it
there. Just as nice would be a way to get the file as a unicode string,
I suppose.
(This is related to another thread I've recently posted to, where
another user was having trouble with pydoc's links to source files using
the file: protocol. I suggested having pydoc serve the source files,
and provided a patch, but it's crossed my mind that it would be nice to
tell the browser the encoding of that file.
Jeff
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/python-list/attachments/20041016/7e532cc1/attachment.sig>
More information about the Python-list
mailing list