BUG: On Py3.10 importing `scipy.x` fails
See original GitHub issueDescribe your issue.
Importing scipy.signal
under Py3.10 (in a venv) fails with this message (on Py3.9.4 and older it works):
$ python3
Python 3.10.0a6 (default, Mar 2 2021, 02:01:08) [GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import scipy.signal
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "~/vgl310/lib/python3.10/site-packages/scipy/signal/__init__.py", line 302, in <module>
from .filter_design import *
File "~/vgl310/lib/python3.10/site-packages/scipy/signal/filter_design.py", line 16, in <module>
from scipy import special, optimize, fft as sp_fft
File "~/vgl310/lib/python3.10/site-packages/scipy/optimize/__init__.py", line 421, in <module>
from ._shgo import shgo
File "~/vgl310/lib/python3.10/site-packages/scipy/optimize/_shgo.py", line 9, in <module>
from scipy import spatial
File "~/vgl310/lib/python3.10/site-packages/scipy/spatial/__init__.py", line 107, in <module>
from . import distance, transform
File "/home/ullix/geigerlog/vgl310/lib/python3.10/site-packages/scipy/spatial/transform/__init__.py", line 19, in <module>
from .rotation import Rotation, Slerp
ImportError: /home/ullix/geigerlog/vgl310/lib/python3.10/site-packages/scipy/spatial/transform/rotation.cpython-310-x86_64-linux-gnu.so: undefined symbol: _PyGen_Send
The latest version of scipy is installed:
$ python3 -m pip install -U scipy
Requirement already satisfied: scipy in ~/vgl310/lib/python3.10/site-packages (1.6.1)
Requirement already satisfied: numpy>=1.16.5 in ~/vgl310/lib/python3.10/site-packages (from scipy) (1.21.2)
Reproducing Code Example
-
Error message
-
SciPy/NumPy/Python version information
import sys, scipy, numpy; print(scipy.__version__, numpy.__version__, sys.version_info) 1.6.1 1.21.2 sys.version_info(major=3, minor=10, micro=0, releaselevel='alpha', serial=6)
Issue Analytics
- State:
- Created 2 years ago
- Reactions:3
- Comments:9 (6 by maintainers)
Top Results From Across the Web
BUG: Cannot install SciPy 1.9.3 in Python 3.10 in macOS
mesonpy-flu011q5/build']' returned non-zero exit status 1. [end of output] note: This error originates from a subprocess, and is likely not a ...
Read more >SciPy 1.8.0 Release Notes — SciPy v1.9.3 Manual
Our development attention will now shift to bug-fix releases on the 1.8.x branch, ... #15316: BUG: Failed to install scipy 1.7.x with pypy...
Read more >1926090 – python-tabulate fails to build with Python 3.10
1926090 – python-tabulate fails to build with Python 3.10: ImportError: cannot import name 'Iterable' from 'collections' Summary: python-tabulate fails to ...
Read more >The 10 Most Common Mistakes That Python Developers Make
Common Mistake #9: Failing to address differences between Python 2 and Python 3. Consider the following file foo.py : import sys def bar(i):...
Read more >What's New In Python 3.8 — Python 3.11.1 documentation
On Unix, when Python is built in debug mode, import now also looks for C ... to python3-config --libs (without --embed ) if...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
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
A release is in the making (cf the branch 1.7.2 and #14567). It just takes time out of our limited resources.
1.7.2
is released, closing.