On Thu, Oct 14, 2010 at 02:25, Antoine Pitrou <solip...@pitrou.net> wrote:
>
> Hello,
>
> In the http://bugs.python.org/issue10093 discussion, I proposed to add a
> specific warning category for unclosed files. The rationale is that
> these warnings will happen in destructors and therefore filtering by
> line number and filename doesn't make sense. So a new category would be
> useful in order to allow defining specific rules.
> Do you think it would go against the moratorium?

As one of the co-authors of the PEP I say no.

>
> As for the category name, I would suggest ResourceWarning if we use it
> specifically for resource-consumption warnings. Or perhaps DebugWarning
> if we want to put all kinds of debugging helpers in it.

I say start with ResourceWarning and if we decide to generalize we can
make ResourceWarning subclass DebugWarning without breaking code.
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to