A RetroSearch Logo

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

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/attachments/20070904/a598e9d5/attachment.htm below:

On 04/09/07, <b class="gmail_sendername">Guido van Rossum</b> &lt;<a href="mailto:guido@python.org">guido@python.org</a>&gt; wrote:<div><span class="gmail_quote"></span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Is this on OSX? That test has been failing (because on that platform<br>sqrt(-1) returns nan instead of raising ValueError) for years -- but<br>the test is only run when run in verbose mode, which mostly hides the<br>issue.&nbsp;&nbsp;Have you read the comment for the test?
</blockquote><div><br>Indeed, I am on OSX. Yes, I have read the comment for the test. Would the following pseudocode be an acceptable fix for the problem:<br>if sys.platform == &#39;darwin&#39; and math.sqrt(-1) == nan:<br>
&nbsp; &nbsp;&nbsp; return<br>else:<br>&nbsp; try:<br>&nbsp; &nbsp;&nbsp; x = math.sqrt(-1)<br>&nbsp; except ValueError: <br>&nbsp; &nbsp;&nbsp; pass <br>&nbsp; ... <br>or should I just not bother?<br></div></div>-- <br>Cheers,<br>Hasan Diwan &lt;<a href="mailto:hasan.diwan@gmail.com">
hasan.diwan@gmail.com</a>&gt;

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