This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author baikie
Recipients baikie
Date 2008-06-01.22:22:06
SpamBayes Score 0.0105907
Marked as misclassified No
Message-id <>
The error message has no newline at the end:

$ LANG=en_GB.UTF-8 python3.0 $'\xff'
Could not convert argument 2 to string$

Seriously, though: is this the intended behaviour?  If the
interpreter just dies when it gets a non-UTF-8 (or whatever)
argument, it creates an opportunity for a denial-of-service if
some admin is running a Python script via find(1) or similar.
And what if you want to run a Python script on some files named
in a mixture of charsets (because, say, you just untarred an
archive created in a foreign charset)?

Could sys.argv not provide bytes objects for those arguments,
like os.listdir()?  Or (better IMHO) have a separate
sys.argv_bytes interface?
Date User Action Args
2008-06-01 22:22:20baikiesetspambayes_score: 0.0105907 -> 0.0105907
recipients: + baikie
2008-06-01 22:22:17baikiesetspambayes_score: 0.0105907 -> 0.0105907
messageid: <>
2008-06-01 22:22:14baikielinkissue3023 messages
2008-06-01 22:22:09baikiecreate