Assertions are bad, m'kay?

Chris Angelico rosuav at gmail.com
Fri Mar 7 02:16:55 EST 2014


They produce the wrong exception type, they disappear when you least
expect them, and now we have another reason not to use assert.

http://xkcd.com/1339/

Abusing assert for arg checking violates XKCD 1339. Write
standards-compliant code!

ChrisA



More information about the Python-list mailing list