On Mon, Sep 29, 2008 at 12:17 PM, Robert Kern <robert.kern@gmail.com> wrote:
On Mon, Sep 29, 2008 at 13:07, Charles R Harris
<charlesr.harris@gmail.com> wrote:
>
> On Mon, Sep 29, 2008 at 11:50 AM, Robert Kern <robert.kern@gmail.com> wrote:
>>
>> On Mon, Sep 29, 2008 at 12:40, Charles R Harris
>> <charlesr.harris@gmail.com> wrote:
>> >
>> > On Mon, Sep 29, 2008 at 11:35 AM, Robert Kern <robert.kern@gmail.com>
>> > wrote:
>> >>
>> >> On Mon, Sep 29, 2008 at 12:30, Charles R Harris
>> >> <charlesr.harris@gmail.com> wrote:
>> >> >
>> >> > On Mon, Sep 29, 2008 at 11:27 AM, Robert Kern <robert.kern@gmail.com>
>> >> > wrote:
>>
>> >> >> When is -OO ever used for running tests? The assert statement is
>> >> >> used
>> >> >> for tests under nose.
>> >> >
>> >> > When it is the default on windows platforms. There was a ticket..
>> >>
>> >> I see #893, which talks about when -OO is used explicitly and when
>> >> numpy is part of a py2exe application. This does not refer to any
>> >> default configuration on Windows platforms.
>> >
>> > Let's put it this way, if the tests were consistent with assert then
>> > they
>> > couldn't be run with the -OO option. If they *can* be run with the -OO
>> > option then they had better run correctly.
>>
>> I'm afraid that I don't understand what you are referring to.
>
> Asserts are transparent. If they go away, programs containing asserts should
> still run correctly. It's like bounds checking in array references, say in
> the std::vector class. If compiled with -DNODEBUG, the programs still run.
> Programs shouldn't use asserts for non-debugging purposes, they should raise
> real exceptions. If you think the numpy tests are essentially debugging
> tests, then they should all disappear when run with the -OO option, i.e.,
> nose should do nothing. If nose wants to make that change, that is fine with
> me. But as is, incorrect failures may be reported and that is an error.

What failures?

Read the ticket. And if a test incorrectly passes, that is also an error. Wrong is wrong, programming ain't philosophy.

Chuck