[issue18269] Clarify which integer is required in os.chmod() exception
anatoly techtonik
report at bugs.python.org
Fri Jun 21 00:02:59 CEST 2013
anatoly techtonik added the comment:
Right. This report is about improving error message. It doesn't say what is expected where. If you have a call like:
os.fchmod(outfile, unixperm)
it is easy to assume that unixperm is not integer, while in fact the problem is in outfile. This could not be actual for Python 3, but it seems that there is bug with it as well.
>>> v = open("VERSION")
>>> import os
>>> os.fchmod(v, 0664)
File "<stdin>", line 1
os.fchmod(v, 0664)
^
SyntaxError: invalid token
>>>
----------
assignee: -> docs at python
components: +Documentation
resolution: invalid ->
status: closed -> open
versions: +Python 2.7, Python 3.3
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue18269>
_______________________________________
More information about the Python-bugs-list
mailing list