From 39d56a4130e6c67dc1bfbca5d5a654e857a12f2c Mon Sep 17 00:00:00 2001 From: adrinjalali Date: Mon, 4 Mar 2024 11:54:26 +0100 Subject: [PATCH 1/3] CI pin pytest to <8 for flaky --- skops/_min_dependencies.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/skops/_min_dependencies.py b/skops/_min_dependencies.py index 0a8290a8..38380a44 100644 --- a/skops/_min_dependencies.py +++ b/skops/_min_dependencies.py @@ -1,7 +1,8 @@ """All minimum dependencies for scikit-learn.""" import argparse -PYTEST_MIN_VERSION = "5.0.1" +# TODO: flaky fails on pytest=8 +PYTEST_MIN_VERSION = ">=7,<8" # 'build' and 'install' is included to have structured metadata for CI. # It will NOT be included in setup's extras_require From bff2578f89691fc85a2e911071ebe25b6bdb629c Mon Sep 17 00:00:00 2001 From: adrinjalali Date: Mon, 4 Mar 2024 12:22:59 +0100 Subject: [PATCH 2/3] alternative method --- .github/workflows/build-test.yml | 1 + .github/workflows/deploy-model-card-creator.yml | 1 + skops/_min_dependencies.py | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index fdc845c5..f60e8d5d 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -54,6 +54,7 @@ jobs: - name: Install dependencies run: | + pip install pytest<8 pip install .[docs,tests] pip install black=="23.9.1" ruff=="0.0.292" mypy=="1.6.0" pip uninstall --yes scikit-learn diff --git a/.github/workflows/deploy-model-card-creator.yml b/.github/workflows/deploy-model-card-creator.yml index 9758972b..28aa88a3 100644 --- a/.github/workflows/deploy-model-card-creator.yml +++ b/.github/workflows/deploy-model-card-creator.yml @@ -25,6 +25,7 @@ jobs: - name: Install dependencies run: | + pip install pytest<8 pip install -e .[docs,tests] python --version pip --version diff --git a/skops/_min_dependencies.py b/skops/_min_dependencies.py index 38380a44..2a9856bd 100644 --- a/skops/_min_dependencies.py +++ b/skops/_min_dependencies.py @@ -2,7 +2,7 @@ import argparse # TODO: flaky fails on pytest=8 -PYTEST_MIN_VERSION = ">=7,<8" +PYTEST_MIN_VERSION = "7" # 'build' and 'install' is included to have structured metadata for CI. # It will NOT be included in setup's extras_require From 3b84336d1fb8f3fd81c9ed520f15617e910489b7 Mon Sep 17 00:00:00 2001 From: adrinjalali Date: Mon, 4 Mar 2024 15:15:17 +0100 Subject: [PATCH 3/3] fix bash --- .github/workflows/build-test.yml | 2 +- .github/workflows/deploy-model-card-creator.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index f60e8d5d..4170295c 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -54,7 +54,7 @@ jobs: - name: Install dependencies run: | - pip install pytest<8 + pip install "pytest<8" pip install .[docs,tests] pip install black=="23.9.1" ruff=="0.0.292" mypy=="1.6.0" pip uninstall --yes scikit-learn diff --git a/.github/workflows/deploy-model-card-creator.yml b/.github/workflows/deploy-model-card-creator.yml index 28aa88a3..258269e8 100644 --- a/.github/workflows/deploy-model-card-creator.yml +++ b/.github/workflows/deploy-model-card-creator.yml @@ -25,7 +25,7 @@ jobs: - name: Install dependencies run: | - pip install pytest<8 + pip install "pytest<8" pip install -e .[docs,tests] python --version pip --version