Pin pandas to exclude 3.0.4 (segfault constructing pd.Timedelta on Python 3.14) - #23022
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (9)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughSummary by CodeRabbit
WalkthroughNarrows pandas version constraints in ChangesPandas 3.0.4 exclusion
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested labels
Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@dependencies.yaml`:
- Around line 917-920: The `pandas 3.0.4` exclusion is still being bypassed in
the test selectors, so update the selector definitions for
`test_python_cudf_common` and `test_cudf_pandas_compat` to exclude `3.0.4` as
well. Make the same version constraint used by the `pandas` dependency anchor
apply in these test env selectors so Python 3.14 jobs cannot resolve to the
broken release. Locate the relevant test selector entries by their names and
ensure they no longer allow `pandas==3.0.*` without the explicit `!=3.0.4`
guard.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: e0f954f8-749c-42e9-b67b-13c2028a7ca3
📒 Files selected for processing (8)
conda/environments/all_cuda-129_arch-aarch64.yamlconda/environments/all_cuda-129_arch-x86_64.yamlconda/environments/all_cuda-133_arch-aarch64.yamlconda/environments/all_cuda-133_arch-x86_64.yamldependencies.yamlpython/cudf/pyproject.tomlpython/dask_cudf/pyproject.tomlpython/pylibcudf/pyproject.toml
…t selectors The run_common runtime pin covers wheel/conda installs, but the test_python_cudf_common (oldest) and test_cudf_pandas_compat matrix selectors still listed a bare pandas==3.0.*, which can resolve to the broken 3.0.4 on Python 3.14. Mirror the !=3.0.4 exclusion there too. Addresses CodeRabbit review on PR NVIDIA#23022.
Per review, cap below 3.0.4 rather than excluding only that exact version: we can't assume a later 3.0.x will be fixed, so this avoids auto-upgrading into another broken release. Raise the bound once an upstream fix is confirmed (pandas-dev/pandas#66086).
|
/merge |
Description
pandas 3.0.4 (released 2026-06-28) segfaults when constructing any
pd.Timedeltaon Python 3.14, which crashesimport cudfat module-load time (theDatetimeIndexclass body inpython/cudf/cudf/core/index.pybuilds a set ofpd.Timedeltaconstants). This breaks all of cudf / cudf.pandas and thepandas-testsCI job (pytest segfaults during collection, before any test runs).Minimal reproducer — pristine venv with only
pandas==3.0.4+numpyon CPython 3.14, no cudf involved:It is a regression from pandas 3.0.3 (works) — pandas is the only changed package — and reproduces with numpy 2.3.3 (pandas 3.0.4's own declared minimum for py3.14) and 2.4.6. The faulthandler C stack shows unbounded recursion between
pandas/_libs/tslibs/timedeltasand numpy's_multiarray_umath.Filed upstream: pandas-dev/pandas#66086
This PR pins
pandas != 3.0.4in the runtime dependency (run_commonindependencies.yaml, regenerated into the wheel/conda metadata). The exclusion form (rather than<3.0.4) lets a fixed pandas (e.g. 3.0.5) be picked up automatically; the pin should be removed once that ships.Checklist