Fails to install on Python 3.10 because of Numpy dependency
See original GitHub issueHow to reproduce the bug
python3.10 -m pip install apache-superset
Expected results
Correct install
Actual results
errors: see screenshots
Screenshots

Environment
Ubuntu 22.04 with Python 3.10
Checklist
Make sure to follow these steps before submitting your issue - thank you!
- [y ] I have checked the superset logs for python stacktraces and included it here as text if there are any.
- [y ] I have reproduced the issue with at least the latest released version of superset.
- [ y] I have checked the issue tracker for the same issue and I haven’t found one similar.
Additional context
Not sure why numpy 1.19.4 is being targeted, when the main config file stipulates numpy=1.21.? There must be a conflicting internal dependency via another package during the build stage.
It’s potentially pyarrow==5.0.0 causing the problem, as when try to pip install pyarrow=5.0.0 standalone the same problem arises.
This is conmfirmed by the project.toml for pyarrow=5.0.0:
[build-system]
requires = [
"cython >= 0.29",
"numpy==1.16.6; python_version<'3.9'",
"numpy==1.19.4; python_version>='3.9'",
"setuptools",
"setuptools_scm",
"wheel"
]
Recommendation
If possible, Superset’s pyarrow dependency should be upgraded to 6.0.0:
[build-system]
requires = [
"cython >= 0.29",
"numpy==1.16.6; python_version<'3.9'",
"numpy==1.19.4; python_version=='3.9'",
"numpy==1.21.3; python_version>'3.9'",
"setuptools",
"setuptools_scm",
"wheel"
]
Issue Analytics
- State:
- Created a year ago
- Reactions:7
- Comments:9
Top Results From Across the Web
Can't install numpy on python 3.10
I managed to solve the problem by installing not the newest numpy 1.22. 2 in pip.
Read more >Issues in installation in Python 3.10
Encountered error while trying to install package. ╰─> numpy ... pip subprocess to install build dependencies did not run successfully. │ exit code:...
Read more >Installing NumPy
Install Python from python.org, Homebrew, or your Linux package manager. Use Poetry as the most well-maintained tool that provides a dependency resolver and ......
Read more >Package installation issues | PyCharm Documentation
The package cannot be installed because the Python version doesn't satisfy the package requirement. Try to create another Python interpreter ...
Read more >Error installing Pystan in python 3.10 with gcc 9.2.0
I am trying to install fbprophet in python. This has pystan 2.19.1.1 as a dependency. Running pip install pystan==2.19.1.1 gives me the following...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

IMO @betodealmeida this has been closed prematurely… not everyone can downgrade to py3.9 easily and for now my workaround is I have to back off of using Ubuntu 22.04 in favor of 20.04 (which didn’t work either so… I will keep plugging away)
I see some packages got bumped by someone but… pip installing latest I am still hitting the issue
EDIT: I guess this will come in a subsequent release like
2.0.xhi, installing python 3.10 is not working so we have to downgrade python 3.9 and install it.
sudo add-apt-repository ppa:deadsnakes/ppa sudo apt install python3.9 python3.9 --version python3.9 -m venv venv sudo apt-get install python3.9-venv python3.9 -m venv venv . venv/bin/activate pip install apache-superset sudo apt-get install build-essential libssl-dev libffi-dev python3.9-dev libsasl2-dev libldap2-dev pip install apache-superset superset db upgrade #<if result = error then run below command> export FLASK_APP=superset sudo apt install redis-server pip uninstall -y Werkzeug pip install Werkzeug==2.0.3 superset db upgrade superset --version pip uninstall flask pip install flask==2.1.3 superset db upgrade superset fab create-admin superset init pip install pillow superset init superset run -p 8088 --with-threads --reload --debugger #<else > export FLASK_APP=superset superset fab create-admin superset init superset run -p 8088 --with-threads --reload --debugger