Skip to content

Commit 705ff81

Browse files
author
Sylvain MARIE
committed
Merge branch 'main' of https://github.com/pandas-dev/pandas into feature/44764_perf_issue_new_period
2 parents a69aeca + 920c025 commit 705ff81

File tree

182 files changed

+3875
-2460
lines changed

Some content is hidden

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

182 files changed

+3875
-2460
lines changed

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

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@ on:
44
push:
55
branches:
66
- main
7+
- 2.0.x
78
- 1.5.x
89
pull_request:
910
branches:
1011
- main
12+
- 2.0.x
1113
- 1.5.x
1214
paths-ignore:
1315
- "doc/**"
@@ -52,3 +54,7 @@ jobs:
5254
name: Test results
5355
path: test-data.xml
5456
if: failure()
57+
concurrency:
58+
# https://github.community/t/concurrecy-not-work-for-push/183068/7
59+
group: ${{ github.event_name == 'push' && github.run_number || github.ref }}-32bit
60+
cancel-in-progress: true

.github/workflows/code-checks.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@ on:
44
push:
55
branches:
66
- main
7+
- 2.0.x
78
- 1.5.x
89
pull_request:
910
branches:
1011
- main
12+
- 2.0.x
1113
- 1.5.x
1214

1315
env:

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,14 @@ on:
44
push:
55
branches:
66
- main
7+
- 2.0.x
78
- 1.5.x
89
tags:
910
- '*'
1011
pull_request:
1112
branches:
1213
- main
14+
- 2.0.x
1315
- 1.5.x
1416

1517
env:

.github/workflows/macos-windows.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@ on:
44
push:
55
branches:
66
- main
7+
- 2.0.x
78
- 1.5.x
89
pull_request:
910
branches:
1011
- main
12+
- 2.0.x
1113
- 1.5.x
1214
paths-ignore:
1315
- "doc/**"
@@ -16,8 +18,6 @@ env:
1618
PANDAS_CI: 1
1719
PYTEST_TARGET: pandas
1820
PATTERN: "not slow and not db and not network and not single_cpu"
19-
ERROR_ON_WARNINGS: "1"
20-
2121

2222
permissions:
2323
contents: read

.github/workflows/package-checks.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@ on:
44
push:
55
branches:
66
- main
7+
- 2.0.x
78
- 1.5.x
89
pull_request:
910
branches:
1011
- main
12+
- 2.0.x
1113
- 1.5.x
1214
types: [ labeled, opened, synchronize, reopened ]
1315

.github/workflows/sdist.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@ on:
44
push:
55
branches:
66
- main
7+
- 2.0.x
78
- 1.5.x
89
pull_request:
910
branches:
1011
- main
12+
- 2.0.x
1113
- 1.5.x
1214
types: [labeled, opened, synchronize, reopened]
1315
paths-ignore:

.github/workflows/ubuntu.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@ on:
44
push:
55
branches:
66
- main
7+
- 2.0.x
78
- 1.5.x
89
pull_request:
910
branches:
1011
- main
12+
- 2.0.x
1113
- 1.5.x
1214
paths-ignore:
1315
- "doc/**"
@@ -38,7 +40,6 @@ jobs:
3840
- name: "Minimum Versions"
3941
env_file: actions-38-minimum_versions.yaml
4042
pattern: "not slow and not network and not single_cpu"
41-
error_on_warnings: "0"
4243
- name: "Locale: it_IT"
4344
env_file: actions-38.yaml
4445
pattern: "not slow and not network and not single_cpu"
@@ -63,12 +64,10 @@ jobs:
6364
env_file: actions-310.yaml
6465
pattern: "not slow and not network and not single_cpu"
6566
pandas_copy_on_write: "1"
66-
error_on_warnings: "0"
6767
- name: "Data Manager"
6868
env_file: actions-38.yaml
6969
pattern: "not slow and not network and not single_cpu"
7070
pandas_data_manager: "array"
71-
error_on_warnings: "0"
7271
- name: "Pypy"
7372
env_file: actions-pypy-38.yaml
7473
pattern: "not slow and not network and not single_cpu"
@@ -77,7 +76,6 @@ jobs:
7776
env_file: actions-310-numpydev.yaml
7877
pattern: "not slow and not network and not single_cpu"
7978
test_args: "-W error::DeprecationWarning -W error::FutureWarning"
80-
error_on_warnings: "0"
8179
exclude:
8280
- env_file: actions-38.yaml
8381
pyarrow_version: "8"
@@ -97,7 +95,6 @@ jobs:
9795
ENV_FILE: ci/deps/${{ matrix.env_file }}
9896
PATTERN: ${{ matrix.pattern }}
9997
EXTRA_APT: ${{ matrix.extra_apt || '' }}
100-
ERROR_ON_WARNINGS: ${{ matrix.error_on_warnings || '1' }}
10198
LANG: ${{ matrix.lang || '' }}
10299
LC_ALL: ${{ matrix.lc_all || '' }}
103100
PANDAS_DATA_MANAGER: ${{ matrix.pandas_data_manager || 'block' }}

.github/workflows/wheels.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,8 @@ jobs:
173173
pip install hypothesis>=6.34.2 pytest>=7.0.0 pytest-xdist>=2.2.0 pytest-asyncio>=0.17
174174
cd .. # Not a good idea to test within the src tree
175175
python -c "import pandas; print(pandas.__version__);
176-
pandas.test(extra_args=['-m not clipboard and not single_cpu', '--skip-slow', '--skip-network', '--skip-db', '-n=2']);
177-
pandas.test(extra_args=['-m not clipboard and single_cpu', '--skip-slow', '--skip-network', '--skip-db'])"
176+
pandas.test(extra_args=['-m not clipboard and not single_cpu and not slow and not network and not db', '-n 2']);
177+
pandas.test(extra_args=['-m not clipboard and single_cpu and not slow and not network and not db'])"
178178
- uses: actions/upload-artifact@v3
179179
with:
180180
name: sdist

.pre-commit-config.yaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ repos:
313313
entry: python scripts/generate_pip_deps_from_conda.py
314314
files: ^(environment.yml|requirements-dev.txt)$
315315
pass_filenames: false
316-
additional_dependencies: [pyyaml, toml]
316+
additional_dependencies: [tomli, pyyaml]
317317
- id: title-capitalization
318318
name: Validate correct capitalization among titles in documentation
319319
entry: python scripts/validate_rst_title_capitalization.py
@@ -391,10 +391,11 @@ repos:
391391
types: [yaml]
392392
- id: validate-min-versions-in-sync
393393
name: Check minimum version of dependencies are aligned
394-
entry: python scripts/validate_min_versions_in_sync.py
394+
entry: python -m scripts.validate_min_versions_in_sync
395395
language: python
396396
files: ^(ci/deps/actions-.*-minimum_versions\.yaml|pandas/compat/_optional\.py)$
397-
additional_dependencies: [tomli]
397+
additional_dependencies: [tomli, pyyaml]
398+
pass_filenames: false
398399
- id: validate-errors-locations
399400
name: Validate errors locations
400401
description: Validate errors are in appropriate locations.

asv_bench/benchmarks/frame_methods.py

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,21 @@
1717
from .pandas_vb_common import tm
1818

1919

20+
class Clip:
21+
params = [
22+
["float64", "Float64", "float64[pyarrow]"],
23+
]
24+
param_names = ["dtype"]
25+
26+
def setup(self, dtype):
27+
data = np.random.randn(100_000, 10)
28+
df = DataFrame(data, dtype=dtype)
29+
self.df = df
30+
31+
def time_clip(self, dtype):
32+
self.df.clip(-1.0, 1.0)
33+
34+
2035
class GetNumericData:
2136
def setup(self):
2237
self.df = DataFrame(np.random.randn(10000, 25))
@@ -739,4 +754,29 @@ def time_memory_usage_object_dtype(self):
739754
self.df2.memory_usage(deep=True)
740755

741756

757+
class FindValidIndex:
758+
param_names = ["dtype"]
759+
params = [
760+
["float", "Float64", "float64[pyarrow]"],
761+
]
762+
763+
def setup(self, dtype):
764+
df = DataFrame(
765+
np.random.randn(100000, 2),
766+
columns=list("AB"),
767+
dtype=dtype,
768+
)
769+
df.iloc[:100, 0] = None
770+
df.iloc[:200, 1] = None
771+
df.iloc[-100:, 0] = None
772+
df.iloc[-200:, 1] = None
773+
self.df = df
774+
775+
def time_first_valid_index(self, dtype):
776+
self.df.first_valid_index()
777+
778+
def time_last_valid_index(self, dtype):
779+
self.df.last_valid_index()
780+
781+
742782
from .pandas_vb_common import setup # noqa: F401 isort:skip

0 commit comments

Comments
 (0)