You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some test cases under test_sphere.py with a dependency on scipy.spatial.Delaunay are being skipped regardless of the dependency being satisfied. This is because the optional package check ( optional_package("scipy.spatial.Delaunay") ) internally uses importlib.import_module() to check if the dependency is satisfied. But since scipy.spatial.Delaunay is a class and not a module, it throws a ModuleNotFoundError and fails.
Way to reproduce
Code example
>>> import scipy.spatial.Delaunay
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'scipy.spatial.Delaunay'
>>> importlib.import_module('scipy.spatial.Delaunay')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\sukru\miniconda3\envs\tf\lib\importlib\__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'scipy.spatial.Delaunay'
Description
Some test cases under test_sphere.py with a dependency on scipy.spatial.Delaunay are being skipped regardless of the dependency being satisfied. This is because the optional package check ( optional_package("scipy.spatial.Delaunay") ) internally uses importlib.import_module() to check if the dependency is satisfied. But since scipy.spatial.Delaunay is a class and not a module, it throws a ModuleNotFoundError and fails.
Way to reproduce
The text was updated successfully, but these errors were encountered: