<br><div class="gmail_quote">On Fri, Aug 26, 2011 at 8:47 PM, Steven D'Aprano <span dir="ltr"><<a href="mailto:steve@pearwood.info">steve@pearwood.info</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im">Antoine Pitrou wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
On Fri, 26 Aug 2011 17:25:56 -0700<br>
Dan Stromberg <<a href="mailto:drsalists@gmail.com" target="_blank">drsalists@gmail.com</a>> wrote:<br>
</blockquote></div><div class="im">If you add regex as "import regex", and the new regex module doesn't work<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
out, regex might be harder to get rid of. from __future__ import is an<br>
established way of trying something for a while to see if it's going to<br>
work.<br>
</blockquote>
<br>
That's an interesting idea. This way, integrating the new module would<br>
be a less risky move, since if it gives us too many problems, we could<br>
back out our decision in the next feature release.<br>
</blockquote>
<br></div>
I'm not sure that's correct. If there are differences in either the interface or the behaviour between the new regex and re, then reverting will be a pain regardless of whether you have:<br>
<br>
from __future__ import re<br>
re.compile(...)<br>
<br>
or<br>
<br>
import regex<br>
regex.compile(...)<br>
<br>
<br>
Either way, if the new regex library goes away, code will break, and fixing it may not be easy.</blockquote><div><br>You're talking technically, which is important, but wasn't what I was suggesting would be helped.<br>
<br>Politically, and from a marketing standpoint, it's easier to withdraw a feature you've given with a "Play with this, see if it works for you" warning. <br><br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Have then been any __future__ features that were added provisionally?<br></blockquote><div><br>I can't either, but ISTR hearing that from __future__ import was started with such an intent. Irrespective, it's hard to import something from "future" without at least suspecting that you're on the bleeding edge.<br>
<br><br></div></div>