[Bug 184920] Re: import numpy fails after Py_Finalize in embedded python
Launchpad Bug Tracker
184920 at bugs.launchpad.net
Thu Jun 13 04:17:21 UTC 2013
[Expired for python-numpy (Ubuntu) because there has been no activity
for 60 days.]
** Changed in: python-numpy (Ubuntu)
Status: Incomplete => Expired
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to python-numpy in Ubuntu.
https://bugs.launchpad.net/bugs/184920
Title:
import numpy fails after Py_Finalize in embedded python
Status in “python-numpy” package in Ubuntu:
Expired
Bug description:
Binary package hint: python-numpy
I am writing an application that embeds python and invokes scripts
that import numpy. I have found that while numpy will import correctly
the first time, if I run Py_Finalize() and then reinitialize the
python interpreter, the second time numpy is imported I get this
error:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/usr/local/lib/rtxi/rtxilib.py", line 3, in <module>
from numpy import ndarray, array, empty
File "/usr/lib/python2.5/site-packages/numpy/__init__.py", line 36, in <module>
import core
File "/usr/lib/python2.5/site-packages/numpy/core/__init__.py", line 5, in <module>
import multiarray
SystemError: dynamic module not initialized properly
The workaround is to simply skip the call to Py_Finalize(). This problem was discussed on the scipy mailing list previously:
http://projects.scipy.org/pipermail/numpy-discussion/2007-April.txt.gz
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python-numpy/+bug/184920/+subscriptions
More information about the foundations-bugs
mailing list