A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2009-June/090051.html below:

[Python-Dev] Iterator version of contextlib.nested

[Python-Dev] Iterator version of contextlib.nested [Python-Dev] Iterator version of contextlib.nestedNick Coghlan ncoghlan at gmail.com
Mon Jun 15 12:47:45 CEST 2009
Hagen Fürstenau wrote:
>> I actually almost asked for that to be changed to a
>> PendingDeprecationWarning when it was first added - Benjamin, do you
>> mind if I downgrade this warning to a pending one post rc2?
> 
> I'm not sure what that would buy us. For the use case I mentioned it
> would be just as annoying to get a PendingDeprecationWarning. But if the
> warning was completely removed now, nested could still get deprecated in
> 3.2 as soon as some better mechanism for a variable number of managers
> has been provided.

Unlike a full DeprecationWarning, a PendingDeprecationWarning is ignored
by default. You have to switch them on explicitly via code or a command
line switch in order to see them.

Pending warnings give the hint that we intend to get rid of something,
but either don't have clear replacements for some legitimate use cases
(as in the case of contextlib.nested) or have some other reason for not
generating a warning by default (e.g. we may not have cleared all uses
out of the standard library yet).

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia
---------------------------------------------------------------
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4