[New-bugs-announce] [issue2280] parser module chokes on unusual characters
David Binger
report at bugs.python.org
Wed Mar 12 19:33:05 CET 2008
New submission from David Binger <davidbinger at mac.com>:
This is with the current revision of py3k: 61353.
parser.suite('"\u1234"') fails with a TypeError.
Changing the argument format from "s" to "s#" works around this problem.
I added a unit test for this. After fixing the "s#", another
bug is exposed by the same test: a string literal containing
\u1234 is mangled by sequence2st().
The last section of the patch seems to correct the second bug.
(I think getarg.c's handling of "s" has a problem
handling a unicode string containing a character whose
encoding is not 1 byte. It has a test for null bytes
at the end that does not work correctly.)
----------
components: Library (Lib)
files: parsermodule.patch
keywords: patch
messages: 63482
nosy: dbinger
severity: normal
status: open
title: parser module chokes on unusual characters
type: behavior
versions: Python 3.0
Added file: http://bugs.python.org/file9662/parsermodule.patch
__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue2280>
__________________________________
More information about the New-bugs-announce
mailing list