[SciPy-Dev] import scipy.stats hangs in mod_python application

josef.pktd@gmai... josef.pktd@gmai...
Sun Aug 28 18:26:08 CDT 2011

On Sun, Aug 28, 2011 at 7:01 PM, fork <forkandwait@gmail.com> wrote:
> Hi all,
> This may be really tricky to diagnose, given all the rather weird parameters,
> but here goes:
> I have a mod_python application that takes a bunch of mortality rates via a
> form, and processes them with scipy, numpy, and matplotlib. It is running on a
> Gentoo box.  (Gentoo + mod_python seemed like a good idea at the time, but so
> did the Edsel... anyway, I still have to maintain this beast...)
> In the multitude of files that get loaded when a mod_python based page is
> called, there is a line "import scipy.stats as ST".  That line works just great
> if I am running python at the command line, but it hangs forever when in the
> modpython application; I know this because I have run it both with an exception
> before it (barfs on the exception) and after it (just sits there, no errors to
> the apache log, etc).
> scipy.__version__ 0.9.0
> python is 2.7.1
> Anybody have any ideas how to fix this or even diagnose it?

I have no idea about the actual problem, but scipy.stats requires or
loads many of the other scipy subpackages. Since stats is relatively
light in compiled extension modules, maybe trying to load first the
other subpackages might help to narrow it down.
import scipy
import scipy.special
sparse, optimize, ...


> _______________________________________________
> SciPy-Dev mailing list
> SciPy-Dev@scipy.org
> http://mail.scipy.org/mailman/listinfo/scipy-dev

More information about the SciPy-Dev mailing list