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 terry.reedy
Recipients terry.reedy, thatiparthy
Date 2013-11-16.00:57:30
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Since failed asserts print the failed assert, repeating the assertion in a message is useless.
>>> assert 1 <= i
Traceback (most recent call last):
  File "<pyshell#3>", line 1, in <module>
    assert 1 <= i

It is already obvious that i must be >= 1. So I would reject the patch.

> And isn't this too much defensive programming?

Whether stdlib python code should have asserts is a more interesting question. I will ask on pydev.
Date User Action Args
2013-11-16 00:57:30terry.reedysetrecipients: + terry.reedy, thatiparthy
2013-11-16 00:57:30terry.reedysetmessageid: <>
2013-11-16 00:57:30terry.reedylinkissue19562 messages
2013-11-16 00:57:30terry.reedycreate