[SciPy-Dev] request for testing: SciPy 0.7.2 RC1 + NumPy 1.4.1 RC1

Ralf Gommers ralf.gommers@googlemail....
Wed Apr 7 12:13:56 CDT 2010


On Thu, Apr 8, 2010 at 1:00 AM, <josef.pktd@gmail.com> wrote:

> On Wed, Apr 7, 2010 at 12:31 PM, Ralf Gommers
>  >>
> >> don't backport the *raising* of the DepreciationWarning, it's supposed
> >> to be a warning and not an exception in 0.7   It hasn't been
> >> backported intentionally.
> >
> > OK. Everything else is okay though right?
>
> It looks ok, but I don't think it is a good idea to backport changes
> that are not really necessary. There is always a small chance that
> there was a mistake or incompatibility in the changeset that got
> changed later. I don't think that's the case, but I did several
> followup removal of calls to the depreciated/removed stats functions.
>
> At this stage, I would just release numpy and scipy (if they work) and
> leave cleaning up noisy output and warnings for the next release. (I
> don't have python 2.6, so I haven't tested it yet)
>
> Makes sense. I guess I can't make everyone happy here.


>
> > Fixed:
> >
> > def gcc_exists(name='gcc'):
> >     """ Test to make sure gcc is found."""
> >     result = 0
> >     cmd = [str(name), '-v']
> >     try:
> >         if sys.platform == 'win32':
> >             p = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE,
> >                                  stderr=subprocess.STDOUT)
> >         else:
> >             p = subprocess.Popen(cmd, stdout=subprocess.PIPE,
> >                                  stderr=subprocess.STDOUT)
> >         str_result = p.stdout.read()
> >         if 'specs' in str_result:
> >             result = 1
> >     except:
> >         # This was needed because the msvc compiler messes with
> >         # the path variable. and will occasionlly mess things up
> >         # so much that gcc is lost in the path. (Occurs in test
> >         # scripts)
> >         result = not os.system(" ".join(cmd))
> >     return result
>
> I'm not sure about this. My impression is that the except part
> result = not os.system(" ".join(cmd))
>
> is doing the printing, not subprocess
>
> >>> os.system("gcc2 -v")
> 'gcc2' is not recognized as an internal or external command,
> operable program or batch file.
> 1
>
> That's correct, but the fix in the subprocess call (shell=True) should
ensure that no exception is thrown in the parent process:

>>> subprocess.Popen('abc', shell=True, stdout=subprocess.PIPE,
stderr=subprocess.STDOUT)
<subprocess.Popen object at 0x2182e30>
>>> subprocess.Popen('abc', shell=False, stdout=subprocess.PIPE,
stderr=subprocess.STDOUT)
 ......
OSError: [Errno 2] No such file or directory


Cheers,
Ralf
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-dev/attachments/20100408/bbb40867/attachment.html 


More information about the SciPy-Dev mailing list