Skip to content

Commit 4f49efd

Browse files
committed
Use pandas 3.x only for scikit-learn 1.7 and up
1 parent 461ebbf commit 4f49efd

1 file changed

Lines changed: 13 additions & 13 deletions

File tree

.github/workflows/test.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ jobs:
4343
scikit-learn: "1.3.*"
4444
- python-version: "3.14"
4545
scikit-learn: "1.4.*"
46+
- python-version: "3.14"
47+
scikit-learn: "1.4.*"
48+
- python-version: "3.14"
49+
scikit-learn: "1.5.*"
50+
- python-version: "3.14"
51+
scikit-learn: "1.6.*"
4652

4753
include:
4854
# Full test run on ubuntu, 3.14
@@ -64,14 +70,6 @@ jobs:
6470
sklearn-only: "false"
6571
code-cov: true
6672

67-
# Pandas 2 run
68-
- os: ubuntu-latest
69-
python-version: "3.12"
70-
scikit-learn: "1.5.*"
71-
sklearn-only: "false"
72-
pandas-version: "2.*"
73-
code-cov: false
74-
7573
steps:
7674
- uses: actions/checkout@v6
7775
with:
@@ -82,15 +80,17 @@ jobs:
8280
with:
8381
python-version: ${{ matrix.python-version }}
8482

85-
- name: Install test dependencies, scikit-learn, and optional pandas
83+
- name: Install test dependencies, scikit-learn, and pandas
8684
shell: bash
8785
run: |
8886
python -m pip install --upgrade pip
8987
pip install -e .[test] scikit-learn==${{ matrix.scikit-learn }}
90-
91-
if [ "${{ matrix.pandas-version }}" != "" ]; then
92-
echo "Installing specific pandas version: ${{ matrix.pandas-version }}"
93-
pip install "pandas==${{ matrix.pandas-version }}"
88+
89+
# scikit-learn 1.7+ requires pandas 3.x, earlier versions use pandas 2.x
90+
if [[ "${{ matrix.scikit-learn }}" == "1.7."* ]]; then
91+
pip install "pandas==3.*"
92+
else
93+
pip install "pandas==2.*"
9494
fi
9595
9696
- name: Store repository status

0 commit comments

Comments
 (0)