<br><br><div class="gmail_quote">On Sun, Feb 21, 2010 at 13:31, Guido van Rossum <span dir="ltr">&lt;<a href="mailto:guido@python.org">guido@python.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div class="im">On Sun, Feb 21, 2010 at 1:26 PM, Steven Bethard<br>
&lt;<a href="mailto:steven.bethard@gmail.com">steven.bethard@gmail.com</a>&gt; wrote:<br>
&gt; On Sun, Feb 21, 2010 at 5:45 AM, Guido van Rossum &lt;<a href="mailto:guido@python.org">guido@python.org</a>&gt; wrote:<br>
&gt;&gt; Maybe the best thing is to make optparse *silently* deprecated, with a<br>
&gt;&gt; big hint at the top of its documentation telling new users to use<br>
&gt;&gt; argparse instead, but otherwise leaving it in indefinitely for the<br>
&gt;&gt; benefit of the many existing users.<br>
&gt;<br>
&gt; So basically do what the PEP does now, except don&#39;t remove optparse in<br>
&gt; Python 3.5?  For reference, the current proposal is:<br>
&gt;<br>
&gt; * Python 2.7+ and 3.2+ -- The following note will be added to the<br>
&gt; optparse documentation:<br>
&gt;    The optparse module is deprecated and will not be developed<br>
&gt; further; development will continue with the argparse module.<br>
&gt; * Python 2.7+ -- If the Python 3 compatibility flag, -3, is provided<br>
&gt; at the command line, then importing optparse will issue a<br>
&gt; DeprecationWarning. Otherwise no warnings will be issued.<br>
&gt; * Python 3.2 (estimated Jun 2010) -- Importing optparse will issue a<br>
&gt; PendingDeprecationWarning, which is not displayed by default.<br>
&gt; * Python 3.3 (estimated Jan 2012) -- Importing optparse will issue a<br>
&gt; PendingDeprecationWarning, which is not displayed by default.<br>
&gt; * Python 3.4 (estimated Jun 2013) -- Importing optparse will issue a<br>
&gt; DeprecationWarning, which is displayed by default.<br>
&gt; * Python 3.5 (estimated Jan 2015) -- The optparse module will be removed.<br>
&gt;<br>
&gt; So if I drop that last bullet, is the PEP ready for pronouncement?<br>
<br>
</div>Drop the last two  bullets and it&#39;s a deal. (OTOH AFAIK we changed<br>
DeprecationWarning so it is *not* displayed by default.</blockquote><div><br></div><div>Yes, DeprecationWarning is now silent under Python 2.7 and 3.1 so a DeprecationWarning would only pop up if developers exposed DeprecationWarning. But if the module is not about to be removed in 3.x then I think regardless of the silence of both warnings it should stay PendingDeprecationWarning.</div>

<div><br></div><div>-Brett</div></div>