capitalone / DataProfiler

What's in your data? Extract schema, statistics and entities from datasets
https://capitalone.github.io/DataProfiler
Apache License 2.0
1.44k stars 163 forks source link

ModuleNotFoundError: No module named 'numpy.lib.histograms' #1156

Open alexjdean opened 4 months ago

alexjdean commented 4 months ago

General Information:

Describe the bug: When attempting to setup a Python virtual environment, I run make setup per this Contribution guideline. When the Makefile executes pre-commit run, the check-manifest stage fails with an error of

ImportError:
A module that was compiled using NumPy 1.x cannot be run in
NumPy 2.0.0 as it may crash. To support both 1.x and 2.x
versions of NumPy, modules must be compiled with NumPy 2.0.
Some module may need to rebuild instead e.g. with 'pybind11>=2.12'.

If you are a user of the module, the easiest solution will be to
downgrade to 'numpy<2' or try to upgrade the affected module.
We expect that some modules will need time to support NumPy 2.

Traceback (most recent call last): [...]

ModuleNotFoundError: No module named 'numpy.lib.histograms'

I believe this to be a result of the latest NumPy 2.0.0 release as of three weeks ago.

To Reproduce:

Run make setup per this Contribution guideline.

Expected behavior:

The Python virtual environment should be successfully set up. Instead, I encounter this NumPy error.

Screenshots:

image

Additional context:

This is similar to #1154, however I encounter this issue when setting up the virtual environment rather than running a Python file that imports DataProfiler.

mepwang commented 3 months ago

I tried the following:

pip install -U numpy==1.26

it worked for me

carlsonp commented 2 months ago

I also had to downgrade to numpy 1.X. I suspect the requirements.txt files will need to be updated.