[Python-ideas] Repurpose `assert' into a general-purpose check

smarie sylvain.marie at schneider-electric.com
Tue Jan 16 10:41:10 EST 2018

Le mardi 16 janvier 2018 16:37:29 UTC+1, smarie a écrit :
>     validate is_foo_compliant(x) or is_bar_compliant(x) 
> ValidationError(message)

This was a typo in this case since we use the base ValidationError it even 
would simplify to 

        validate is_foo_compliant(x) or is_bar_compliant(x), message 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20180116/480085f7/attachment.html>

More information about the Python-ideas mailing list