Skip to content

Commit 801d838

Browse files
authored
Merge branch 'main' into update-docs-data-table-representation
2 parents 5955aea + 10102e6 commit 801d838

File tree

16 files changed

+167
-280
lines changed

16 files changed

+167
-280
lines changed

.github/workflows/broken-linkcheck.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/workflows/cache-cleanup-daily.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66

77
jobs:
88
cleanup:
9-
runs-on: ubuntu-latest
9+
runs-on: ubuntu-24.04
1010
if: github.repository_owner == 'pandas-dev'
1111
permissions:
1212
actions: write

.github/workflows/cache-cleanup.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ on:
66

77
jobs:
88
cleanup:
9-
runs-on: ubuntu-latest
9+
runs-on: ubuntu-24.04
10+
if: github.repository_owner == 'pandas-dev'
1011
steps:
1112
- name: Clean Cache
1213
run: |

.github/workflows/comment-commands.yml

Lines changed: 0 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,6 @@ permissions:
99
pull-requests: write
1010

1111
jobs:
12-
issue_assign:
13-
runs-on: ubuntu-24.04
14-
if: (!github.event.issue.pull_request) && github.event.comment.body == 'take'
15-
concurrency:
16-
group: ${{ github.actor }}-issue-assign
17-
steps:
18-
- run: |
19-
echo "Assigning issue ${{ github.event.issue.number }} to ${{ github.event.comment.user.login }}"
20-
curl -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" -d '{"assignees": ["${{ github.event.comment.user.login }}"]}' https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/assignees
2112
preview_docs:
2213
runs-on: ubuntu-24.04
2314
if: github.event.issue.pull_request && github.event.comment.body == '/preview'
@@ -28,64 +19,3 @@ jobs:
2819
with:
2920
previewer-server: "https://pandas.pydata.org/preview"
3021
artifact-job: "Doc Build and Upload"
31-
asv_run:
32-
runs-on: ubuntu-24.04
33-
# TODO: Support more benchmarking options later, against different branches, against self, etc
34-
if: github.event.issue.pull_request && startsWith(github.event.comment.body, '@github-actions benchmark')
35-
defaults:
36-
run:
37-
shell: bash -el {0}
38-
env:
39-
ENV_FILE: environment.yml
40-
COMMENT: ${{github.event.comment.body}}
41-
42-
concurrency:
43-
# Set concurrency to prevent abuse(full runs are ~5.5 hours !!!)
44-
# each user can only run one concurrent benchmark bot at a time
45-
# We don't cancel in progress jobs, but if you want to benchmark multiple PRs, you're gonna have
46-
# to wait
47-
group: ${{ github.actor }}-asv
48-
cancel-in-progress: false
49-
50-
steps:
51-
- name: Checkout
52-
uses: actions/checkout@v5
53-
with:
54-
fetch-depth: 0
55-
56-
# Although asv sets up its own env, deps are still needed
57-
# during discovery process
58-
- name: Set up Conda
59-
uses: ./.github/actions/setup-conda
60-
61-
- name: Run benchmarks
62-
id: bench
63-
continue-on-error: true # asv will exit code 1 for regressions
64-
run: |
65-
# extracting the regex, see https://stackoverflow.com/a/36798723
66-
REGEX=$(echo "$COMMENT" | sed -n "s/^.*-b\s*\(\S*\).*$/\1/p")
67-
cd asv_bench
68-
asv check -E existing
69-
git remote add upstream https://github.com/pandas-dev/pandas.git
70-
git fetch upstream
71-
asv machine --yes
72-
asv continuous -f 1.1 -b $REGEX upstream/main HEAD
73-
echo 'BENCH_OUTPUT<<EOF' >> $GITHUB_ENV
74-
asv compare -f 1.1 upstream/main HEAD >> $GITHUB_ENV
75-
echo 'EOF' >> $GITHUB_ENV
76-
echo "REGEX=$REGEX" >> $GITHUB_ENV
77-
78-
- uses: actions/github-script@v8
79-
env:
80-
BENCH_OUTPUT: ${{env.BENCH_OUTPUT}}
81-
REGEX: ${{env.REGEX}}
82-
with:
83-
script: |
84-
const ENV_VARS = process.env
85-
const run_url = `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${context.runId}`
86-
github.rest.issues.createComment({
87-
issue_number: context.issue.number,
88-
owner: context.repo.owner,
89-
repo: context.repo.repo,
90-
body: '\nBenchmarks completed. View runner logs here.' + run_url + '\nRegex used: '+ 'regex ' + ENV_VARS["REGEX"] + '\n' + ENV_VARS["BENCH_OUTPUT"]
91-
})

.github/workflows/unit-tests.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ jobs:
182182
strategy:
183183
matrix:
184184
# Note: Don't use macOS latest since macos 14 appears to be arm64 only
185-
os: [macos-13, macos-14, windows-latest]
185+
os: [macos-13, macos-14, windows-2025]
186186
env_file: [actions-311.yaml, actions-312.yaml, actions-313.yaml]
187187
fail-fast: false
188188
runs-on: ${{ matrix.os }}
@@ -322,7 +322,7 @@ jobs:
322322
fail-fast: false
323323
matrix:
324324
# Separate out macOS 13 and 14, since macOS 14 is arm64 only
325-
os: [ubuntu-24.04, macOS-13, macOS-14, windows-latest]
325+
os: [ubuntu-24.04, macOS-13, macOS-14, windows-2025]
326326

327327
timeout-minutes: 90
328328

.github/workflows/wheels.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ jobs:
229229
- build_sdist
230230
- build_wheels
231231

232-
runs-on: ubuntu-latest
232+
runs-on: ubuntu-24.04
233233

234234
environment:
235235
name: pypi
@@ -243,6 +243,8 @@ jobs:
243243
with:
244244
path: dist # everything lands in ./dist/**
245245

246+
# TODO: This step can be probably be achieved by actions/download-artifact@v5
247+
# by specifying merge-multiple: true, and a glob pattern
246248
- name: Collect files
247249
run: |
248250
mkdir -p upload

doc/source/development/contributing.rst

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,16 +36,14 @@ and `good first issue
3636
<https://github.com/pandas-dev/pandas/issues?q=is%3Aopen+sort%3Aupdated-desc+label%3A%22good+first+issue%22+no%3Aassignee>`_
3737
are typically good for newer contributors.
3838

39-
Once you've found an interesting issue, it's a good idea to assign the issue to yourself,
40-
so nobody else duplicates the work on it. On the Github issue, a comment with the exact
41-
text ``take`` to automatically assign you the issue
42-
(this will take seconds and may require refreshing the page to see it).
39+
Once you've found an interesting issue, leave a comment with your intention
40+
to start working on it. If somebody else has
41+
already commented on issue but they have shown a lack of activity in the issue
42+
or a pull request in the past 2-3 weeks, you may take it over.
4343

4444
If for whatever reason you are not able to continue working with the issue, please
45-
unassign it, so other people know it's available again. You can check the list of
46-
assigned issues, since people may not be working in them anymore. If you want to work on one
47-
that is assigned, feel free to kindly ask the current assignee if you can take it
48-
(please allow at least a week of inactivity before considering work in the issue discontinued).
45+
leave a comment on an issue, so other people know it's available again. You can check the list of
46+
assigned issues, since people may not be working in them anymore.
4947

5048
We have several :ref:`contributor community <community>` communication channels, which you are
5149
welcome to join, and ask questions as you figure things out. Among them are regular meetings for

doc/source/whatsnew/v3.0.0.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -948,6 +948,7 @@ Datetimelike
948948
- Bug in :class:`Timestamp` constructor failing to raise when given a ``np.datetime64`` object with non-standard unit (:issue:`25611`)
949949
- Bug in :func:`date_range` where the last valid timestamp would sometimes not be produced (:issue:`56134`)
950950
- Bug in :func:`date_range` where using a negative frequency value would not include all points between the start and end values (:issue:`56147`)
951+
- Bug in :func:`to_datetime` where passing an ``lxml.etree._ElementUnicodeResult`` together with ``format`` raised ``TypeError``. Now subclasses of ``str`` are handled. (:issue:`60933`)
951952
- Bug in :func:`tseries.api.guess_datetime_format` would fail to infer time format when "%Y" == "%H%M" (:issue:`57452`)
952953
- Bug in :func:`tseries.frequencies.to_offset` would fail to parse frequency strings starting with "LWOM" (:issue:`59218`)
953954
- Bug in :meth:`DataFrame.fillna` raising an ``AssertionError`` instead of ``OutOfBoundsDatetime`` when filling a ``datetime64[ns]`` column with an out-of-bounds timestamp. Now correctly raises ``OutOfBoundsDatetime``. (:issue:`61208`)
@@ -971,7 +972,6 @@ Datetimelike
971972
- Bug in constructing arrays with :class:`ArrowDtype` with ``timestamp`` type incorrectly allowing ``Decimal("NaN")`` (:issue:`61773`)
972973
- Bug in constructing arrays with a timezone-aware :class:`ArrowDtype` from timezone-naive datetime objects incorrectly treating those as UTC times instead of wall times like :class:`DatetimeTZDtype` (:issue:`61775`)
973974
- Bug in setting scalar values with mismatched resolution into arrays with non-nanosecond ``datetime64``, ``timedelta64`` or :class:`DatetimeTZDtype` incorrectly truncating those scalars (:issue:`56410`)
974-
- Bug in :func:`to_datetime` where passing an ``lxml.etree._ElementUnicodeResult`` together with ``format`` raised ``TypeError``. Now subclasses of ``str`` are handled. (:issue:`60933`)
975975

976976

977977
Timedelta

pandas/tests/io/parser/common/test_chunksize.py

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -295,29 +295,28 @@ def test_empty_with_nrows_chunksize(all_parsers, iterator):
295295
tm.assert_frame_equal(result, expected)
296296

297297

298-
def test_read_csv_memory_growth_chunksize(all_parsers):
298+
def test_read_csv_memory_growth_chunksize(temp_file, all_parsers):
299299
# see gh-24805
300300
#
301301
# Let's just make sure that we don't crash
302302
# as we iteratively process all chunks.
303303
parser = all_parsers
304304

305-
with tm.ensure_clean() as path:
306-
with open(path, "w", encoding="utf-8") as f:
307-
for i in range(1000):
308-
f.write(str(i) + "\n")
309-
310-
if parser.engine == "pyarrow":
311-
msg = "The 'chunksize' option is not supported with the 'pyarrow' engine"
312-
with pytest.raises(ValueError, match=msg):
313-
with parser.read_csv(path, chunksize=20) as result:
314-
for _ in result:
315-
pass
316-
return
317-
318-
with parser.read_csv(path, chunksize=20) as result:
319-
for _ in result:
320-
pass
305+
with open(temp_file, "w", encoding="utf-8") as f:
306+
for i in range(1000):
307+
f.write(str(i) + "\n")
308+
309+
if parser.engine == "pyarrow":
310+
msg = "The 'chunksize' option is not supported with the 'pyarrow' engine"
311+
with pytest.raises(ValueError, match=msg):
312+
with parser.read_csv(temp_file, chunksize=20) as result:
313+
for _ in result:
314+
pass
315+
return
316+
317+
with parser.read_csv(temp_file, chunksize=20) as result:
318+
for _ in result:
319+
pass
321320

322321

323322
def test_chunksize_with_usecols_second_block_shorter(all_parsers):

pandas/tests/io/parser/common/test_iterator.py

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -142,19 +142,18 @@ def test_iterator_skipfooter_errors(all_parsers, kwargs):
142142
pass
143143

144144

145-
def test_iteration_open_handle(all_parsers):
145+
def test_iteration_open_handle(temp_file, all_parsers):
146146
parser = all_parsers
147147
kwargs = {"header": None}
148148

149-
with tm.ensure_clean() as path:
150-
with open(path, "w", encoding="utf-8") as f:
151-
f.write("AAA\nBBB\nCCC\nDDD\nEEE\nFFF\nGGG")
149+
with open(temp_file, "w", encoding="utf-8") as f:
150+
f.write("AAA\nBBB\nCCC\nDDD\nEEE\nFFF\nGGG")
152151

153-
with open(path, encoding="utf-8") as f:
154-
for line in f:
155-
if "CCC" in line:
156-
break
152+
with open(temp_file, encoding="utf-8") as f:
153+
for line in f:
154+
if "CCC" in line:
155+
break
157156

158-
result = parser.read_csv(f, **kwargs)
159-
expected = DataFrame({0: ["DDD", "EEE", "FFF", "GGG"]})
160-
tm.assert_frame_equal(result, expected)
157+
result = parser.read_csv(f, **kwargs)
158+
expected = DataFrame({0: ["DDD", "EEE", "FFF", "GGG"]})
159+
tm.assert_frame_equal(result, expected)

0 commit comments

Comments
 (0)