[SciPy-dev] setup.py traceback

Pearu Peterson pearu at cens.ioc.ee
Mon Sep 30 09:22:16 CDT 2002


On Mon, 30 Sep 2002, Skip Montanaro wrote:

> I just cvsup'd and now get this traceback when executing setup.py (no matter
> which command I try):
> 
>     /usr/local/lib/python2.3/pre.py:94: DeprecationWarning: Please use the
>     're' module, not the 'pre' module DeprecationWarning)
>     Traceback (most recent call last):
>       File "setup.py", line 129, in ?
>         install_package()
>       File "setup.py", line 95, in install_package
>         config.extend([get_package_config(x,parent_package)for x in standard_packages])
>       File "setup.py", line 45, in get_package_config
>         config = mod.configuration(parent)
>       File "linalg/setup_linalg.py", line 33, in configuration
>         atlas_info = get_info('atlas')
>       File "scipy_distutils/system_info.py", line 127, in get_info
>         return cl().get_info()
>       File "scipy_distutils/system_info.py", line 224, in __init__
>         assert type(self.search_static_first) is type(0)
>     AssertionError
> 
> Anyone else seeing this?  I'm running on Mandrake 8.1 with Python CVS.

It must be related to the changes in ConfigParser of Python 2.3 compared
to earlier Python versions.

Note that it may not be safe to just remove this assertion. It really
depends what is the output ConfigParser.getboolean. If it is int or
bool, then change the assert statement to
  assert isinstance(self.search_static_first,int)

But if it is a string, for example, '0' or '1', then removing the assert
statement will lead to incorrect results because self.search_static_first
is later used as

if self.search_static_first:
  #do staff 1
else:
  #do staff 2

and #do staff 1 is executed even if self.search_static_first=='0'.

Hmm, the result of ConfigParser.getboolean could be also None...

So, could you check what is the type/value of self.search_static_first in
your case?

Pearu




More information about the Scipy-dev mailing list