diff --git a/.github/workflows/python-package-conda.yml b/.github/workflows/python-package-conda.yml index 14c138bff..9401458b9 100644 --- a/.github/workflows/python-package-conda.yml +++ b/.github/workflows/python-package-conda.yml @@ -29,7 +29,8 @@ jobs: - name: Install test dependencies (conda) shell: bash -l {0} run: | - conda install -y pytest coverage + # Pinning numpy and scikit-learn to prevent the issues reported in #982 + conda install -y pytest coverage "numpy>=1.22,<2.4" "scikit-learn>=1.0" - name: Install package and run tests shell: bash -l {0} diff --git a/.github/workflows/python-package-pip.yml b/.github/workflows/python-package-pip.yml index 4790b1ecd..ee5825e7a 100644 --- a/.github/workflows/python-package-pip.yml +++ b/.github/workflows/python-package-pip.yml @@ -24,6 +24,8 @@ jobs: - name: Install dependencies (pip) run: | python -m pip install --upgrade pip + # Fixing #982 by pinning numpy + pip install "numpy>=1.22,<2.4" pip install pytest coverage pip install -e . diff --git a/environment.yml b/environment.yml index b1c12c982..96f2cbebc 100644 --- a/environment.yml +++ b/environment.yml @@ -3,7 +3,7 @@ channels: - conda-forge dependencies: - flake8>=4.0.1 - - numpy>=2.3.5 + - numpy>=1.21.0,<2.4.0 - pandas>=2.3.3 - scipy>=1.16.3 - scikit-learn>=1.8.0 @@ -13,4 +13,4 @@ dependencies: - pytest>=6.2.5 - setuptools>=59.4.0 - pip: - - markdown>=3.3.6 \ No newline at end of file + - markdown>=3.3.6