Cooper Lees <m...@cooperlees.com> added the comment:

Totally agree with your example use case. There you have a chance for it being 
useful under certain conditions. In that example there is a passed argument.  
In my example there is no passed argument. Thus, I believe that this will 
generally always be developer error, again, unless I'm missing something here.

My main suggestion here is to just error/warn when no argument at all is passed 
to `contextlib.suppress` and this this context is *never* a chance of it being 
useful. If someone passes None or an empty `Sequence` (or anything non truthy) 
I propose we stay behaving the same as today.

Please feel free to edit the title if that's not clear enough etc.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue46819>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to