Skip to content

Commit 27cf80e

Browse files
authored
Merge branch 'main' into python-db-dtypes-pandas-issue28
2 parents 396da54 + 1be9d38 commit 27cf80e

File tree

328 files changed

+8495
-3549
lines changed

Some content is hidden

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

328 files changed

+8495
-3549
lines changed

.github/actions/build_pandas/action.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ runs:
1212

1313
- name: Build Pandas
1414
run: |
15-
python setup.py build_ext -j 2
15+
python setup.py build_ext -j $N_JOBS
1616
python -m pip install -e . --no-build-isolation --no-use-pep517 --no-index
1717
shell: bash -el {0}
18+
env:
19+
# Cannot use parallel compilation on Windows, see https://github.com/pandas-dev/pandas/issues/30873
20+
N_JOBS: ${{ runner.os == 'Windows' && 1 || 2 }}

.github/workflows/32-bit-linux.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: 32 Bit Linux
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- 1.4.x
8+
pull_request:
9+
branches:
10+
- main
11+
- 1.4.x
12+
paths-ignore:
13+
- "doc/**"
14+
15+
jobs:
16+
pytest:
17+
runs-on: ubuntu-latest
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@v3
21+
with:
22+
fetch-depth: 0
23+
24+
- name: Run 32-bit manylinux2014 Docker Build / Tests
25+
run: |
26+
docker pull quay.io/pypa/manylinux2014_i686
27+
docker run --platform linux/386 -v $(pwd):/pandas quay.io/pypa/manylinux2014_i686 \
28+
/bin/bash -xc "cd pandas && \
29+
/opt/python/cp38-cp38/bin/python -m venv ~/virtualenvs/pandas-dev && \
30+
. ~/virtualenvs/pandas-dev/bin/activate && \
31+
python -m pip install --no-deps -U pip wheel 'setuptools<60.0.0' && \
32+
pip install cython numpy python-dateutil pytz pytest pytest-xdist pytest-asyncio>=0.17 hypothesis && \
33+
python setup.py build_ext -q -j2 && \
34+
python -m pip install --no-build-isolation --no-use-pep517 -e . && \
35+
export PANDAS_CI=1 && \
36+
pytest -m 'not slow and not network and not clipboard and not single_cpu' pandas --junitxml=test-data.xml"
37+
38+
- name: Publish test results for Python 3.8-32 bit full Linux
39+
uses: actions/upload-artifact@v3
40+
with:
41+
name: Test results
42+
path: test-data.xml
43+
if: failure()

.github/workflows/code-checks.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,12 +74,16 @@ jobs:
7474

7575
- name: Install pyright
7676
# note: keep version in sync with .pre-commit-config.yaml
77-
run: npm install -g pyright@1.1.230
77+
run: npm install -g pyright@1.1.247
7878

7979
- name: Build Pandas
8080
id: build
8181
uses: ./.github/actions/build_pandas
8282

83+
- name: Check for no warnings when building single-page docs
84+
run: ci/code_checks.sh single-docs
85+
if: ${{ steps.build.outcome == 'success' }}
86+
8387
- name: Run checks on imported code
8488
run: ci/code_checks.sh code
8589
if: ${{ steps.build.outcome == 'success' }}

.github/workflows/docbuild-and-upload.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ jobs:
3737
run: |
3838
source activate pandas-dev
3939
python web/pandas_web.py web/pandas --target-path=web/build
40+
4041
- name: Build documentation
4142
run: |
4243
source activate pandas-dev
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
name: Windows-MacOS
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- 1.4.x
8+
pull_request:
9+
branches:
10+
- main
11+
- 1.4.x
12+
paths-ignore:
13+
- "doc/**"
14+
15+
env:
16+
PANDAS_CI: 1
17+
PYTEST_TARGET: pandas
18+
PYTEST_WORKERS: auto
19+
PATTERN: "not slow and not db and not network and not single_cpu"
20+
21+
22+
jobs:
23+
pytest:
24+
defaults:
25+
run:
26+
shell: bash -el {0}
27+
timeout-minutes: 90
28+
strategy:
29+
matrix:
30+
os: [macos-latest, windows-latest]
31+
env_file: [actions-38.yaml, actions-39.yaml, actions-310.yaml]
32+
fail-fast: false
33+
runs-on: ${{ matrix.os }}
34+
name: ${{ format('{0} {1}', matrix.os, matrix.env_file) }}
35+
concurrency:
36+
# https://github.community/t/concurrecy-not-work-for-push/183068/7
37+
group: ${{ github.event_name == 'push' && github.run_number || github.ref }}-${{ matrix.env_file }}-${{ matrix.os }}
38+
cancel-in-progress: true
39+
40+
steps:
41+
- name: Checkout
42+
uses: actions/checkout@v3
43+
with:
44+
fetch-depth: 0
45+
46+
- name: Install Dependencies
47+
uses: conda-incubator/setup-miniconda@v2.1.1
48+
with:
49+
mamba-version: "*"
50+
channels: conda-forge
51+
activate-environment: pandas-dev
52+
channel-priority: ${{ matrix.os == 'macos-latest' && 'flexible' || 'strict' }}
53+
environment-file: ci/deps/${{ matrix.env_file }}
54+
use-only-tar-bz2: true
55+
56+
# ImportError: 2): Library not loaded: @rpath/libssl.1.1.dylib
57+
# Referenced from: /Users/runner/miniconda3/envs/pandas-dev/lib/libthrift.0.13.0.dylib
58+
# Reason: image not found
59+
- name: Upgrade pyarrow on MacOS
60+
run: conda install -n pandas-dev -c conda-forge --no-update-deps pyarrow=6
61+
if: ${{ matrix.os == 'macos-latest' }}
62+
63+
- name: Build Pandas
64+
uses: ./.github/actions/build_pandas
65+
66+
- name: Test
67+
run: ci/run_tests.sh
68+
69+
- name: Build Version
70+
run: conda list
71+
72+
- name: Publish test results
73+
uses: actions/upload-artifact@v3
74+
with:
75+
name: Test results
76+
path: test-data.xml
77+
if: failure()
78+
79+
- name: Upload coverage to Codecov
80+
uses: codecov/codecov-action@v2
81+
with:
82+
flags: unittests
83+
name: codecov-pandas
84+
fail_ci_if_error: false

.github/workflows/posix.yml

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
pattern: ["not single_cpu", "single_cpu"]
2929
# Don't test pyarrow v2/3: Causes timeouts in read_csv engine
3030
# even if tests are skipped/xfailed
31-
pyarrow_version: ["5", "7"]
31+
pyarrow_version: ["5", "6", "7"]
3232
include:
3333
- name: "Downstream Compat"
3434
env_file: actions-38-downstream_compat.yaml
@@ -61,7 +61,16 @@ jobs:
6161
env_file: actions-310-numpydev.yaml
6262
pattern: "not slow and not network and not single_cpu"
6363
pandas_testing_mode: "deprecate"
64-
test_args: "-W error"
64+
test_args: "-W error::DeprecationWarning:numpy"
65+
exclude:
66+
- env_file: actions-39.yaml
67+
pyarrow_version: "6"
68+
- env_file: actions-39.yaml
69+
pyarrow_version: "7"
70+
- env_file: actions-310.yaml
71+
pyarrow_version: "6"
72+
- env_file: actions-310.yaml
73+
pyarrow_version: "7"
6574
fail-fast: false
6675
name: ${{ matrix.name || format('{0} pyarrow={1} {2}', matrix.env_file, matrix.pyarrow_version, matrix.pattern) }}
6776
env:
@@ -146,35 +155,21 @@ jobs:
146155
channel-priority: flexible
147156
environment-file: ${{ env.ENV_FILE }}
148157
use-only-tar-bz2: true
149-
if: ${{ env.IS_PYPY == 'false' }} # No pypy3.8 support
150158

151159
- name: Upgrade Arrow version
152160
run: conda install -n pandas-dev -c conda-forge --no-update-deps pyarrow=${{ matrix.pyarrow_version }}
153161
if: ${{ matrix.pyarrow_version }}
154162

155-
- name: Setup PyPy
156-
uses: actions/setup-python@v3
157-
with:
158-
python-version: "pypy-3.8"
159-
if: ${{ env.IS_PYPY == 'true' }}
160-
161-
- name: Setup PyPy dependencies
162-
run: |
163-
# TODO: re-enable cov, its slowing the tests down though
164-
pip install Cython numpy python-dateutil pytz pytest>=6.0 pytest-xdist>=1.31.0 pytest-asyncio>=0.17 hypothesis>=5.5.3
165-
if: ${{ env.IS_PYPY == 'true' }}
166-
167163
- name: Build Pandas
168164
uses: ./.github/actions/build_pandas
169165

170166
- name: Test
171167
run: ci/run_tests.sh
172168
# TODO: Don't continue on error for PyPy
173169
continue-on-error: ${{ env.IS_PYPY == 'true' }}
174-
if: always()
175170

176171
- name: Build Version
177-
run: pushd /tmp && python -c "import pandas; pandas.show_versions();" && popd
172+
run: conda list
178173

179174
- name: Publish test results
180175
uses: actions/upload-artifact@v3

.github/workflows/python-dev.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Unfreeze(by commentingthe if: false() condition) once the
33
# next Python Dev version has released beta 1 and both Cython and numpy support it
44
# After that Python has released, migrate the workflows to the
5-
# posix GHA workflows/Azure pipelines and "freeze" this file by
5+
# posix GHA workflows and "freeze" this file by
66
# uncommenting the if: false() condition
77
# Feel free to modify this comment as necessary.
88

.pre-commit-config.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ repos:
2626
types_or: [python, rst, markdown]
2727
files: ^(pandas|doc)/
2828
- repo: https://github.com/pre-commit/pre-commit-hooks
29-
rev: v4.1.0
29+
rev: v4.2.0
3030
hooks:
3131
- id: debug-statements
3232
- id: end-of-file-fixer
@@ -56,7 +56,7 @@ repos:
5656
hooks:
5757
- id: isort
5858
- repo: https://github.com/asottile/pyupgrade
59-
rev: v2.31.1
59+
rev: v2.32.0
6060
hooks:
6161
- id: pyupgrade
6262
args: [--py38-plus]
@@ -71,7 +71,7 @@ repos:
7171
types: [text] # overwrite types: [rst]
7272
types_or: [python, rst]
7373
- repo: https://github.com/sphinx-contrib/sphinx-lint
74-
rev: v0.2
74+
rev: v0.4.1
7575
hooks:
7676
- id: sphinx-lint
7777
- repo: https://github.com/asottile/yesqa
@@ -89,7 +89,7 @@ repos:
8989
types: [python]
9090
stages: [manual]
9191
# note: keep version in sync with .github/workflows/code-checks.yml
92-
additional_dependencies: ['pyright@1.1.230']
92+
additional_dependencies: ['pyright@1.1.247']
9393
- repo: local
9494
hooks:
9595
- id: flake8-rst

LICENSES/KLIB_LICENSE

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
The MIT License
2+
3+
Copyright (c) 2008- Attractive Chaos <attractor@live.co.uk>
4+
5+
Permission is hereby granted, free of charge, to any person obtaining
6+
a copy of this software and associated documentation files (the
7+
"Software"), to deal in the Software without restriction, including
8+
without limitation the rights to use, copy, modify, merge, publish,
9+
distribute, sublicense, and/or sell copies of the Software, and to
10+
permit persons to whom the Software is furnished to do so, subject to
11+
the following conditions:
12+
13+
The above copyright notice and this permission notice shall be
14+
included in all copies or substantial portions of the Software.
15+
16+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
20+
BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
21+
ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
22+
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23+
SOFTWARE.

LICENSES/ULTRAJSON_LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Portions of code from MODP_ASCII - Ascii transformations (upper/lower, etc)
2828
https://github.com/client9/stringencoders
2929
Copyright (c) 2007 Nick Galbreath -- nickg [at] modp [dot] com. All rights reserved.
3030

31-
Numeric decoder derived from from TCL library
31+
Numeric decoder derived from TCL library
3232
http://www.opensource.apple.com/source/tcl/tcl-14/tcl/license.terms
3333
* Copyright (c) 1988-1993 The Regents of the University of California.
3434
* Copyright (c) 1994 Sun Microsystems, Inc.

0 commit comments

Comments
 (0)