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 flox
Recipients belopolsky, exarkun, ezio.melotti, flox, mark.dickinson
Date 2012-07-21.14:57:57
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1342882678.14.0.368955438687.issue7710@psf.upfronthosting.co.za>
In-reply-to
Content
The behavior seems acceptable in 2.7 too.

>>> int('\0')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ValueError: invalid literal for int() with base 10: ''
>>> int('\01')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ValueError: invalid literal for int() with base 10: '\x01'


>>> int(u'\0')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
UnicodeEncodeError: 'decimal' codec can't encode character u'\x00' in position 0: invalid decimal Unicode string
>>> int(u'\01')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ValueError: invalid literal for int() with base 10: '\x01'
History
Date User Action Args
2012-07-21 14:57:58floxsetrecipients: + flox, exarkun, mark.dickinson, belopolsky, ezio.melotti
2012-07-21 14:57:58floxsetmessageid: <1342882678.14.0.368955438687.issue7710@psf.upfronthosting.co.za>
2012-07-21 14:57:57floxlinkissue7710 messages
2012-07-21 14:57:57floxcreate