Opened 6 years ago
Last modified 6 years ago
#58044 closed defect
Importing numpy in Python3.7 fails — at Initial Version
Reported by: | fmw42 (Fred Weinhaus) | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.5.4 |
Keywords: | Cc: | ||
Port: | py-numpy |
Description
On Mac OSX Sierra, I can load Python3.7 interactively. But it will not import numpy (py37-numpy 1.15.4_0+gfortran)
I get the following:
{{{python3.7
Python 3.7.2 (default, Dec 30 2018, 09:00:52) [Clang 9.0.0 (clang-900.0.39.2)] on darwin Type "help", "copyright", "credits" or "license" for more information.
import numpy
Traceback (most recent call last):
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/core/init.py", line 16, in <module>
from . import multiarray
ImportError: cannot import name 'multiarray' from 'numpy.core' (/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/core/init.py)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module> File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/init.py", line 142, in <module>
from . import add_newdocs
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/add_newdocs.py", line 13, in <module>
from numpy.lib import add_newdoc
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/lib/init.py", line 8, in <module>
from .type_check import *
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/lib/type_check.py", line 11, in <module>
import numpy.core.numeric as _nx
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/core/init.py", line 26, in <module>
raise ImportError(msg)
ImportError:
Importing the multiarray numpy extension module failed. Most
likely you are trying to import a failed build of numpy.
If you're working with a numpy git repo, try git clean -xdf
(removes all
files not under version control). Otherwise reinstall numpy.
Original error was: cannot import name 'multiarray' from 'numpy.core' (/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/numpy/core/init.py)}}}
Can you identify if I am doing something wrong or is this an issue with numpy?