R. David Murray rdmur...@bitdance.com added the comment:
I believe the title problem is solved by PEP 383 in py3k trunk.
--
nosy: +r.david.murray
resolution: - fixed
stage: - committed/rejected
status: open - pending
___
Python tracker
Changes by Benjamin Peterson benja...@python.org:
--
status: pending - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3023
___
___
David Watson bai...@users.sourceforge.net added the comment:
@ Victor Stinner: Yes, the behaviour of those functions is as you
describe - it's been changed since I filed this issue. I do
consider it an improvement.
By the password database, I mean /etc/passwd or replacements that
are
Martin v. Löwis mar...@v.loewis.de added the comment:
By the password database, I mean /etc/passwd or replacements that
are accessible via getpwnam() and friends.
Please only discuss one issue at the time in the bug tracker. This
issue is about invalidly-encoded command-line arguments, not
STINNER Victor victor.stin...@haypocalc.com added the comment:
By the password database, I mean /etc/passwd or replacements that
are accessible via getpwnam() and friends. Users are often
allowed to change things like the GECOS field, and can generally
stick any old junk in there,
Changes by Gabriel Genellina gagsl-...@yahoo.com.ar:
--
nosy: +gagenellina
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3023
___
___
STINNER Victor victor.stin...@haypocalc.com added the comment:
Hmm, yes, I see that the open() builtin doesn't accept bytes
filenames, though os.open() still does.
What? open() builtin, io.open() and os.open() accept bytes filename.
So what *is* os.listdir() supposed to do when it finds an
Dan Dever ded...@verizon.net added the comment:
What if someone puts unconvertible strings in the password database?
Which database? It sounds like a different issue.
It's yet another special case of the more general issue, which is that
Unix strings are strings of bytes that may or may not
Changes by dedded ded...@verizon.net:
--
nosy: +dedded
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3023
___
___
Python-bugs-list mailing list
David Watson [EMAIL PROTECTED] added the comment:
Hmm, yes, I see that the open() builtin doesn't accept bytes
filenames, though os.open() still does. When I saw that you
could pass bytes filenames transparently from os.listdir() to
os.open(), I assumed that this was intentional!
So what *is*
Martin v. Löwis [EMAIL PROTECTED] added the comment:
The issue with unrepresentable file names hasn't been decided yet. One
option is to include the bytes object in that case, instead, noting that
this can only occur on selected platforms. Another option is indeed to
raise an exception, or
Martin v. Löwis [EMAIL PROTECTED] added the comment:
That os.listdir still uses bytes should be changed as well. Both file
names and command line arguments are strings, from the viewpoint of
Python. Nothing else is supported.
--
nosy: +loewis
___
New submission from David Watson [EMAIL PROTECTED]:
The error message has no newline at the end:
$ LANG=en_GB.UTF-8 python3.0 test.py $'\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
13 matches
Mail list logo