[issue32259] Misleading "not iterable" Error Message when generator return a "simple" type, and a tuple is expected

Raymond Hettinger report at bugs.python.org
Sun Dec 10 16:47:16 EST 2017


Raymond Hettinger <raymond.hettinger at gmail.com> added the comment:

@Camion, please adopt a less insistent tone.  We've devoting time and thought to your concerns but are under no obligation to make a change just because you are demanding it.  

Part of learning any programming language is learning to reason from error message to root cause.  Good error messages help, but they don't eliminate the underlying not always comfortable path of learning the world-view of the language and its mechanisms.  That is partly why the devguide includes this passage, "Be careful accepting requests for documentation changes from the rare but vocal category of reader who is looking for vindication for one of their programming errors".

A instructor for several thousand engineers, I've not encountered a single case where the current message has been problematic, nor have we had tracker issue arise over Python's 27 year history.  And so far all the proposed wording changes make the message less accurate in other contexts where the message might arise. Based on that and on the comments by the other respondents, it would reasonable to close this issue.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32259>
_______________________________________


More information about the Python-bugs-list mailing list