Message 181908 - Python tracker

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.

Content
> Not technically the topic of this issue, but should we just lock
> down _Py_Uid_Converter() to ints?

I just copied this code from PyArg_ParseTuple*() for 'l' format.

> This is still accepted:
>
> os.setuid(Decimal("1000.2"))

Any C implemented function which parses an integer argument with PyArg_ParseTuple*() accepts decimals.

>>> chr(65.2)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: integer argument expected, got float
>>> chr(Decimal('65.2'))
'A'

I think this is an offtopic for this issue.