Skip to content

Commit 90b6f7b

Browse files
Merge branch 'main' into pandas.Series.str.find
2 parents 7c97345 + 642d244 commit 90b6f7b

File tree

560 files changed

+6604
-4573
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

560 files changed

+6604
-4573
lines changed

.circleci/config.yml

Lines changed: 19 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,15 @@ jobs:
1515
- checkout
1616
- run:
1717
name: Install Environment and Run Tests
18-
shell: /bin/bash -exuo pipefail
18+
shell: /bin/bash -exo pipefail
1919
command: |
20-
MAMBA_URL="https://github.com/conda-forge/miniforge/releases/download/24.3.0-0/Mambaforge-24.3.0-0-Linux-aarch64.sh"
21-
wget -q $MAMBA_URL -O minimamba.sh
22-
chmod +x minimamba.sh
23-
MAMBA_DIR="$HOME/miniconda3"
24-
rm -rf $MAMBA_DIR
25-
./minimamba.sh -b -p $MAMBA_DIR
26-
export PATH=$MAMBA_DIR/bin:$PATH
20+
MINI_URL="https://github.com/conda-forge/miniforge/releases/download/24.3.0-0/Miniforge3-24.3.0-0-Linux-aarch64.sh"
21+
wget -q $MINI_URL -O Miniforge3.sh
22+
chmod +x Miniforge3.sh
23+
MINI_DIR="$HOME/miniconda3"
24+
rm -rf $MINI_DIR
25+
./Miniforge3.sh -b -p $MINI_DIR
26+
export PATH=$MINI_DIR/bin:$PATH
2727
conda info -a
2828
conda env create -q -n pandas-dev -f $ENV_FILE
2929
conda list -n pandas-dev
@@ -54,7 +54,7 @@ jobs:
5454
/opt/python/cp311-cp311/bin/python -m venv ~/virtualenvs/pandas-dev
5555
. ~/virtualenvs/pandas-dev/bin/activate
5656
python -m pip install --no-cache-dir -U pip wheel setuptools meson-python==0.13.1 meson[ninja]==1.2.1
57-
python -m pip install --no-cache-dir versioneer[toml] cython numpy python-dateutil pytz pytest>=7.3.2 pytest-xdist>=2.2.0 hypothesis>=6.46.1
57+
python -m pip install --no-cache-dir versioneer[toml] cython numpy python-dateutil pytz pytest>=7.3.2 pytest-xdist>=3.4.0 hypothesis>=6.84.0
5858
python -m pip install --no-cache-dir --no-build-isolation -e . --config-settings=setup-args="--werror"
5959
python -m pip list --no-cache-dir
6060
export PANDAS_CI=1
@@ -97,21 +97,16 @@ jobs:
9797

9898
- run:
9999
name: Install Anaconda Client & Upload Wheels
100+
shell: /bin/bash -exo pipefail
100101
command: |
101-
echo "Install Mambaforge"
102-
MAMBA_URL="https://github.com/conda-forge/miniforge/releases/download/24.3.0-0/Mambaforge-24.3.0-0-Linux-aarch64.sh"
103-
echo "Downloading $MAMBA_URL"
104-
wget -q $MAMBA_URL -O minimamba.sh
105-
chmod +x minimamba.sh
106-
107-
MAMBA_DIR="$HOME/miniconda3"
108-
rm -rf $MAMBA_DIR
109-
./minimamba.sh -b -p $MAMBA_DIR
110-
111-
export PATH=$MAMBA_DIR/bin:$PATH
112-
113-
mamba install -y -c conda-forge anaconda-client
114-
102+
MINI_URL="https://github.com/conda-forge/miniforge/releases/download/24.3.0-0/Miniforge3-24.3.0-0-Linux-aarch64.sh"
103+
wget -q $MINI_URL -O Miniforge3.sh
104+
chmod +x Miniforge3.sh
105+
MINI_DIR="$HOME/miniconda3"
106+
rm -rf $MINI_DIR
107+
./Miniforge3.sh -b -p $MINI_DIR
108+
export PATH=$MINI_DIR/bin:$PATH
109+
conda install -y -c conda-forge anaconda-client
115110
source ci/upload_wheels.sh
116111
set_upload_vars
117112
upload_wheels
@@ -141,11 +136,9 @@ workflows:
141136
only: /^v.*/
142137
matrix:
143138
parameters:
144-
cibw-build: ["cp39-manylinux_aarch64",
145-
"cp310-manylinux_aarch64",
139+
cibw-build: ["cp310-manylinux_aarch64",
146140
"cp311-manylinux_aarch64",
147141
"cp312-manylinux_aarch64",
148-
"cp39-musllinux_aarch64",
149142
"cp310-musllinux_aarch64",
150143
"cp311-musllinux_aarch64",
151144
"cp312-musllinux_aarch64",]

.gitattributes

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ ci export-ignore
6868
doc export-ignore
6969
gitpod export-ignore
7070
MANIFEST.in export-ignore
71-
scripts export-ignore
71+
scripts/** export-ignore
7272
typings export-ignore
7373
web export-ignore
7474
CITATION.cff export-ignore
@@ -82,3 +82,7 @@ setup.py export-ignore
8282
# csv_dir_path fixture checks the existence of the directory
8383
# exclude the whole directory to avoid running related tests in sdist
8484
pandas/tests/io/parser/data export-ignore
85+
86+
# Include cibw script in sdist since it's needed for building wheels
87+
scripts/cibw_before_build.sh -export-ignore
88+
scripts/cibw_before_test.sh -export-ignore

.github/actions/build_pandas/action.yml

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,6 @@ inputs:
44
editable:
55
description: Whether to build pandas in editable mode (default true)
66
default: true
7-
meson_args:
8-
description: Extra flags to pass to meson
9-
required: false
10-
cflags_adds:
11-
description: Items to append to the CFLAGS variable
12-
required: false
137
runs:
148
using: composite
159
steps:
@@ -30,12 +24,11 @@ runs:
3024

3125
- name: Build Pandas
3226
run: |
33-
export CFLAGS="$CFLAGS ${{ inputs.cflags_adds }}"
3427
if [[ ${{ inputs.editable }} == "true" ]]; then
35-
pip install -e . --no-build-isolation -v --no-deps ${{ inputs.meson_args }} \
28+
pip install -e . --no-build-isolation -v --no-deps \
3629
--config-settings=setup-args="--werror"
3730
else
38-
pip install . --no-build-isolation -v --no-deps ${{ inputs.meson_args }} \
31+
pip install . --no-build-isolation -v --no-deps \
3932
--config-settings=setup-args="--werror"
4033
fi
4134
shell: bash -el {0}

.github/actions/run-tests/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ runs:
77
shell: bash -el {0}
88

99
- name: Publish test results
10-
uses: actions/upload-artifact@v3
10+
uses: actions/upload-artifact@v4
1111
with:
1212
name: Test results
1313
path: test-data.xml
1414
if: failure()
1515

1616
- name: Upload coverage to Codecov
17-
uses: codecov/codecov-action@v3
17+
uses: codecov/codecov-action@v4
1818
with:
1919
flags: unittests
2020
name: codecov-pandas

.github/workflows/package-checks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ jobs:
5353
runs-on: ubuntu-22.04
5454
strategy:
5555
matrix:
56-
python-version: ['3.9', '3.10', '3.11']
56+
python-version: ['3.10', '3.11']
5757
fail-fast: false
5858
name: Test Conda Forge Recipe - Python ${{ matrix.python-version }}
5959
concurrency:

.github/workflows/unit-tests.yml

Lines changed: 64 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
timeout-minutes: 90
2727
strategy:
2828
matrix:
29-
env_file: [actions-39.yaml, actions-310.yaml, actions-311.yaml, actions-312.yaml]
29+
env_file: [actions-310.yaml, actions-311.yaml, actions-312.yaml]
3030
# Prevent the include jobs from overriding other jobs
3131
pattern: [""]
3232
include:
@@ -35,7 +35,7 @@ jobs:
3535
pattern: "not slow and not network and not single_cpu"
3636
pytest_target: "pandas/tests/test_downstream.py"
3737
- name: "Minimum Versions"
38-
env_file: actions-39-minimum_versions.yaml
38+
env_file: actions-310-minimum_versions.yaml
3939
pattern: "not slow and not network and not single_cpu"
4040
- name: "Locale: it_IT"
4141
env_file: actions-311.yaml
@@ -57,6 +57,9 @@ jobs:
5757
# Also install zh_CN (its encoding is gb2312) but do not activate it.
5858
# It will be temporarily activated during tests with locale.setlocale
5959
extra_loc: "zh_CN"
60+
- name: "Future infer strings"
61+
env_file: actions-311.yaml
62+
pandas_future_infer_string: "1"
6063
- name: "Pypy"
6164
env_file: actions-pypy-39.yaml
6265
pattern: "not slow and not network and not single_cpu"
@@ -74,9 +77,10 @@ jobs:
7477
PATTERN: ${{ matrix.pattern }}
7578
LANG: ${{ matrix.lang || 'C.UTF-8' }}
7679
LC_ALL: ${{ matrix.lc_all || '' }}
77-
PANDAS_CI: ${{ matrix.pandas_ci || '1' }}
80+
PANDAS_CI: '1'
81+
PANDAS_FUTURE_INFER_STRING: ${{ matrix.pandas_future_infer_string || '0' }}
7882
TEST_ARGS: ${{ matrix.test_args || '' }}
79-
PYTEST_WORKERS: ${{ matrix.pytest_workers || 'auto' }}
83+
PYTEST_WORKERS: 'auto'
8084
PYTEST_TARGET: ${{ matrix.pytest_target || 'pandas' }}
8185
NPY_PROMOTION_STATE: ${{ matrix.env_file == 'actions-311-numpydev.yaml' && 'weak' || 'legacy' }}
8286
# Clipboard tests
@@ -88,7 +92,7 @@ jobs:
8892

8993
services:
9094
mysql:
91-
image: mysql:8.0.33
95+
image: mysql:8
9296
env:
9397
MYSQL_ALLOW_EMPTY_PASSWORD: yes
9498
MYSQL_DATABASE: pandas
@@ -101,7 +105,7 @@ jobs:
101105
- 3306:3306
102106

103107
postgres:
104-
image: postgres:13
108+
image: postgres:16
105109
env:
106110
PGUSER: postgres
107111
POSTGRES_USER: postgres
@@ -116,7 +120,7 @@ jobs:
116120
- 5432:5432
117121

118122
moto:
119-
image: motoserver/moto:4.1.13
123+
image: motoserver/moto:5.0.0
120124
env:
121125
AWS_ACCESS_KEY_ID: foobar_key
122126
AWS_SECRET_ACCESS_KEY: foobar_secret
@@ -146,9 +150,8 @@ jobs:
146150
- name: Build Pandas
147151
id: build
148152
uses: ./.github/actions/build_pandas
149-
with:
150-
meson_args: ${{ matrix.meson_args }}
151-
cflags_adds: ${{ matrix.cflags_adds }}
153+
# TODO: Re-enable once Pypy has Pypy 3.10 on conda-forge
154+
if: ${{ matrix.name != 'Pypy' }}
152155

153156
- name: Test (not single_cpu)
154157
uses: ./.github/actions/run-tests
@@ -170,7 +173,7 @@ jobs:
170173
matrix:
171174
# Note: Don't use macOS latest since macos 14 appears to be arm64 only
172175
os: [macos-13, macos-14, windows-latest]
173-
env_file: [actions-39.yaml, actions-310.yaml, actions-311.yaml, actions-312.yaml]
176+
env_file: [actions-310.yaml, actions-311.yaml, actions-312.yaml]
174177
fail-fast: false
175178
runs-on: ${{ matrix.os }}
176179
name: ${{ format('{0} {1}', matrix.os, matrix.env_file) }}
@@ -228,7 +231,7 @@ jobs:
228231
. ~/virtualenvs/pandas-dev/bin/activate
229232
python -m pip install --no-cache-dir -U pip wheel setuptools meson[ninja]==1.2.1 meson-python==0.13.1
230233
python -m pip install numpy --config-settings=setup-args="-Dallow-noblas=true"
231-
python -m pip install --no-cache-dir versioneer[toml] cython python-dateutil pytz pytest>=7.3.2 pytest-xdist>=2.2.0 hypothesis>=6.46.1
234+
python -m pip install --no-cache-dir versioneer[toml] cython python-dateutil pytz pytest>=7.3.2 pytest-xdist>=3.4.0 hypothesis>=6.84.0
232235
python -m pip install --no-cache-dir --no-build-isolation -e . --config-settings=setup-args="--werror"
233236
python -m pip list --no-cache-dir
234237
export PANDAS_CI=1
@@ -266,7 +269,7 @@ jobs:
266269
/opt/python/cp311-cp311/bin/python -m venv ~/virtualenvs/pandas-dev
267270
. ~/virtualenvs/pandas-dev/bin/activate
268271
python -m pip install --no-cache-dir -U pip wheel setuptools meson-python==0.13.1 meson[ninja]==1.2.1
269-
python -m pip install --no-cache-dir versioneer[toml] cython numpy python-dateutil pytz pytest>=7.3.2 pytest-xdist>=2.2.0 hypothesis>=6.46.1
272+
python -m pip install --no-cache-dir versioneer[toml] cython numpy python-dateutil pytz pytest>=7.3.2 pytest-xdist>=3.4.0 hypothesis>=6.84.0
270273
python -m pip install --no-cache-dir --no-build-isolation -e . --config-settings=setup-args="--werror"
271274
python -m pip list --no-cache-dir
272275
@@ -300,7 +303,7 @@ jobs:
300303
# To freeze this file, uncomment out the ``if: false`` condition, and migrate the jobs
301304
# to the corresponding posix/windows-macos/sdist etc. workflows.
302305
# Feel free to modify this comment as necessary.
303-
if: false # Uncomment this to freeze the workflow, comment it to unfreeze
306+
# if: false # Uncomment this to freeze the workflow, comment it to unfreeze
304307
defaults:
305308
run:
306309
shell: bash -eou pipefail {0}
@@ -315,7 +318,7 @@ jobs:
315318

316319
concurrency:
317320
# https://github.community/t/concurrecy-not-work-for-push/183068/7
318-
group: ${{ github.event_name == 'push' && github.run_number || github.ref }}-${{ matrix.os }}-${{ matrix.pytest_target }}-dev
321+
group: ${{ github.event_name == 'push' && github.run_number || github.ref }}-${{ matrix.os }}-python-dev
319322
cancel-in-progress: true
320323

321324
env:
@@ -332,21 +335,65 @@ jobs:
332335
- name: Set up Python Dev Version
333336
uses: actions/setup-python@v5
334337
with:
335-
python-version: '3.12-dev'
338+
python-version: '3.13-dev'
336339

337340
- name: Build Environment
338341
run: |
339342
python --version
340343
python -m pip install --upgrade pip setuptools wheel meson[ninja]==1.2.1 meson-python==0.13.1
341344
python -m pip install --pre --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple numpy
342345
python -m pip install versioneer[toml]
343-
python -m pip install python-dateutil pytz tzdata cython hypothesis>=6.46.1 pytest>=7.3.2 pytest-xdist>=2.2.0 pytest-cov
346+
python -m pip install python-dateutil pytz tzdata cython hypothesis>=6.84.0 pytest>=7.3.2 pytest-xdist>=3.4.0 pytest-cov
347+
python -m pip install -ve . --no-build-isolation --no-index --no-deps --config-settings=setup-args="--werror"
348+
python -m pip list
349+
350+
- name: Run Tests
351+
uses: ./.github/actions/run-tests
352+
353+
python-freethreading:
354+
defaults:
355+
run:
356+
shell: bash -eou pipefail {0}
357+
runs-on: ubuntu-22.04
358+
359+
timeout-minutes: 90
360+
361+
concurrency:
362+
# https://github.community/t/concurrecy-not-work-for-push/183068/7
363+
group: ${{ github.event_name == 'push' && github.run_number || github.ref }}-${{ matrix.os }}-python-freethreading-dev
364+
cancel-in-progress: true
365+
366+
env:
367+
PYTEST_WORKERS: "auto"
368+
PANDAS_CI: 1
369+
PATTERN: "not slow and not network and not clipboard and not single_cpu"
370+
PYTEST_TARGET: pandas
371+
372+
steps:
373+
- uses: actions/checkout@v4
374+
with:
375+
fetch-depth: 0
376+
377+
- name: Set up Python Free-threading Version
378+
uses: deadsnakes/[email protected]
379+
with:
380+
python-version: 3.13-dev
381+
nogil: true
382+
383+
- name: Build Environment
384+
run: |
385+
python --version
386+
python -m pip install --upgrade pip setuptools wheel meson[ninja]==1.2.1 meson-python==0.13.1
387+
python -m pip install --pre --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple numpy cython
388+
python -m pip install versioneer[toml]
389+
python -m pip install python-dateutil pytz tzdata hypothesis>=6.84.0 pytest>=7.3.2 pytest-xdist>=3.4.0 pytest-cov
344390
python -m pip install -ve . --no-build-isolation --no-index --no-deps --config-settings=setup-args="--werror"
345391
python -m pip list
346392
347393
- name: Run Tests
348394
uses: ./.github/actions/run-tests
349395

396+
# NOTE: this job must be kept in sync with the Pyodide build job in wheels.yml
350397
emscripten:
351398
# Note: the Python version, Emscripten toolchain version are determined
352399
# by the Pyodide version. The appropriate versions can be found in the

0 commit comments

Comments
 (0)