Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: C extension: numpy.core.multiarray failed to import not built. #18281

Closed
maestropandy opened this issue Nov 14, 2017 · 5 comments
Closed
Labels
Build Library building on various platforms Needs Info Clarification about behavior needed to assess issue
Milestone

Comments

@maestropandy
Copy link

When I am installing devstack-single node openstack package, It needs pandas, while installing facing error as below

ImportError: C extension: numpy.core.multiarray failed to import not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext --inplace --force' to build the C extensions first.

If do manual installation of pandas by using "python setup.py build_ext --inplace --force" from source its running fine, but cannot instruct other dependencies software to clone and do it forcefully.

it will be good if installed normally than force inplace

@maestropandy
Copy link
Author

Here is the call from openstack script to install numpy

`# numpy compat
from pandas.compat.numpy import *

try:
from pandas._libs import (hashtable as _hashtable,
lib as _lib,
tslib as _tslib)
except ImportError as e: # pragma: no cover
# hack but overkill to use re
module = str(e).replace('cannot import name ', '')
raise ImportError("C extension: {0} not built. If you want to import "
"pandas from the source directory, you may need to run "
"'python setup.py build_ext --inplace --force' to build "
"the C extensions first.".format(module))
`

@gfyoung gfyoung added the Build Library building on various platforms label Nov 16, 2017
@gfyoung
Copy link
Member

gfyoung commented Nov 16, 2017

@maestropandy : Thanks for reporting this! Looks like a numpy issue though IIUC. Not sure how pandas would help you out here? (numpy packages are failing to be built)

@TomAugspurger
Copy link
Contributor

@maestropandy for us to help, you'll need to provide more info on how you're installing things.

@TomAugspurger TomAugspurger added the Needs Info Clarification about behavior needed to assess issue label Nov 16, 2017
@samlcharreyron
Copy link

samlcharreyron commented Nov 29, 2017

I have the same issue on OSX Sierra when using homebrew python and numpy and installing pandas via pip. After a bit more research it seems like I was having this issue.

#18530

@jorisvandenbossche
Copy link
Member

Yes, this is an issue with the wheels hosted on PyPI for 0.21.0 (our bad). You can pip install a new version of the wheels with the command specified here: #18530 (comment)

Closing this as it is covered by #18530

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Library building on various platforms Needs Info Clarification about behavior needed to assess issue
Projects
None yet
Development

No branches or pull requests

5 participants