<div dir="ltr"><div>OK, in that case I'll just pronounce approval right here. Considered disagreement is acceptable.<br><br></div>Nick, congrats with PEP 565! Please update the PEP to mark it as approved with a link to this message as the resolution, and let's get the implementation into 3.7a4!<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Dec 12, 2017 at 2:58 PM, Victor Stinner <span dir="ltr"><<a href="mailto:victor.stinner@gmail.com" target="_blank">victor.stinner@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<span class=""><br>
2017-12-12 21:21 GMT+01:00 Guido van Rossum <<a href="mailto:guido@python.org">guido@python.org</a>>:<br>
> I'm still hoping to accept this PEP, but I don't have time to wrap my head<br>
> around -Xdev ("devmode"?) which appears to be Victor's latest pet project.<br>
> Should PEP 565 be changed to copy with devmode's behavior, or the other way<br>
> around, or should they just ignore each other? It is not clear of me what<br>
> the status of the mention in PEP 565 of -Xdev is -- normative or<br>
> informational? I really don't want to have to learn how devmode works in<br>
> order to be able to accept PEP 565 (or send it back for revision), so I am<br>
> asking you two to let me know.<br>
<br>
</span>The warnings filters had a few corner cases. We discussed with Nick to<br>
fix them to make them simpler. We agreed on these priorities for<br>
command line options and environment variables:<br>
<br>
-b and -bb > -W > PYTHONWARNINGS > -X dev > default filters<br>
<br>
In release mode, the default filters became:<br>
<span class=""><br>
    ignore::DeprecationWarning<br>
    ignore::<wbr>PendingDeprecationWarning<br>
    ignore::ImportWarning<br>
</span>    ignore::ResourceWarning<br>
<br>
ignore::BytesWarning is gone. We now rely on the fact the BytesWarning<br>
should not be emited without -b nor -bb in practice.<br>
<br>
It has been implemented in <a href="https://bugs.python.org/issue32230" rel="noreferrer" target="_blank">https://bugs.python.org/<wbr>issue32230</a> ! (I<br>
just merged Nick's PR.)<br>
<br>
<br>
Now -X dev behaves again as my initial propopal: for warnings, "-X<br>
dev" simply behaves  as "-W default". (Previously, I had to hack the<br>
code to respect -b and -bb options, but I don't think that it's worth<br>
it to explain that here, it's doesn't matter anymore ;-))<br>
<br>
The PEP 565 is still different: it doesn't behaves as "-W default",<br>
but "-W default::DeprecationWarning:__<wbr>main__". Only DeprecationWarning<br>
warnings are shown, whereas -X dev shows DeprecationWarning, but also<br>
PendingDeprecationWarning, ResourceWarning and ImportWarning.<br>
Moreover, -X dev shows warnings in all modules, not only __main__.<br>
<br>
You may see -X dev as a builtin linter, whereas PEP 565 seems to be<br>
very specific to one specific issue: display deprecation warnings, but<br>
only in the __main__ module.<br>
<br>
Does it help you to understand the difference?<br>
<br>
<br>
Note: I still dislike the PEP 565, but well, that's just my opinion ;-)<br>
<span class="HOEnZb"><font color="#888888"><br>
Victor<br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">--Guido van Rossum (<a href="http://python.org/~guido" target="_blank">python.org/~guido</a>)</div>
</div>