BLD: Fix CI Tests / Sphinx-Pytest-Coverage (conda-forge) failing
Changes in environment resulting in failure in CI Tests / Sphinx-Pytest-Coverage (conda-forge)
Most recent working CI Tests / Sphinx-Pytest-Coverage (conda-forge) run:
| package | version | CI |
|---|---|---|
| pandas | 2.0.0 (py39h2ad29b5_0) | link |
| pillow | 10.0.1 (py39h444a776_1) | link |
Most recent (broken) CI Tests / Sphinx-Pytest-Coverage (conda-forge) run:
| package | version | CI |
|---|---|---|
| pandas | 2.2.2 (py39hfc16268_1) | link |
| pillow | 10.4.0 (py39h16a7006_0) | link |
Failure in CI:
https://github.com/metoppv/improver/actions/runs/9810862589/job/27091941214?pr=2003
...
File "/usr/share/miniconda/envs/imconda-forge/lib/python3.9/site-packages/PIL/Image.py", line 68, in <module>
from ._typing import StrOrBytesPath, TypeGuard
File "/usr/share/miniconda/envs/imconda-forge/lib/python3.9/site-packages/PIL/_typing.py", line 10, in <module>
NumpyArray = npt.NDArray[Any]
AttributeError: module 'numpy.typing' has no attribute 'NDArray'
after pinning pillow only, we get a little further but still fails:
https://github.com/metoppv/improver/actions/runs/9835034815/job/27147915426#step:6:519
WARNING: autodoc: failed to import module 'dataframe_utilities' from module 'improver.calibration'; the following exception was raised:
C extension: None not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext' to build the C extensions first.
WARNING: autodoc: failed to import module 'dz_rescaling' from module 'improver.calibration'; the following exception was raised:
C extension: None not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext' to build the C extensions first.
Issues
- Closes https://github.com/metoppv/improver/issues/2010
It's gotten further with the pinned pillow package but we do still fail, perhaps related to this warning:
WARNING: autodoc: failed to import module 'dataframe_utilities' from module 'improver.calibration'; the following exception was raised:
C extension: None not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext' to build the C extensions first.
WARNING: autodoc: failed to import module 'dz_rescaling' from module 'improver.calibration'; the following exception was raised:
C extension: None not built. If you want to import pandas from the source directory, you may need to run 'python setup.py build_ext' to build the C extensions first.
pinning pandas resolved the remaining failure. Updating the description accordingly.
On approval, I'll open a PR targeting the improver feedstock.