Skip to content

Backport PR #47979 on branch 1.4.x (DEPS: Update cython) #48009

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion asv_bench/asv.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
// followed by the pip installed packages).
"matrix": {
"numpy": [],
"Cython": ["0.29.30"],
"Cython": ["0.29.32"],
"matplotlib": [],
"sqlalchemy": [],
"scipy": [],
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/actions-310-numpydev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ dependencies:
- pytz
- pip
- pip:
- cython==0.29.30 # GH#34014
- cython==0.29.32
- "--extra-index-url https://pypi.anaconda.org/scipy-wheels-nightly/simple"
- "--pre"
- "numpy"
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/actions-310.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ dependencies:
- python=3.10

# test dependencies
- cython=0.29.30
- cython>=0.29.32
- pytest>=6.0
- pytest-cov
- pytest-xdist>=1.31
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/actions-38-downstream_compat.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ dependencies:
- python=3.8

# test dependencies
- cython=0.29.30
- cython>=0.29.32
- pytest>=6.0
- pytest-cov
- pytest-xdist>=1.31
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/actions-38-minimum_versions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dependencies:
- python=3.8.0

# test dependencies
- cython=0.29.30
- cython>=0.29.32
- pytest>=6.0
- pytest-cov
- pytest-xdist>=1.31
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/actions-38.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ dependencies:
- python=3.8

# test dependencies
- cython=0.29.30
- cython>=0.29.32
- pytest>=6.0
- pytest-cov
- pytest-xdist>=1.31
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/actions-39.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ dependencies:
- python=3.9

# test dependencies
- cython=0.29.30
- cython>=0.29.32
- pytest>=6.0
- pytest-cov
- pytest-xdist>=1.31
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/actions-pypy-38.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ dependencies:
- python=3.8[build=*_pypy] # TODO: use this once pypy3.8 is available

# tools
- cython>=0.29.30
- cython>=0.29.32
- pytest>=6.0
- pytest-cov
- pytest-asyncio
Expand Down
2 changes: 1 addition & 1 deletion ci/deps/circle-38-arm64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ dependencies:
- python=3.8

# test dependencies
- cython=0.29.30
- cython>=0.29.32
- pytest>=6.0
- pytest-cov
- pytest-xdist>=1.31
Expand Down
3 changes: 2 additions & 1 deletion doc/source/whatsnew/v1.4.4.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ including other versions of pandas.

Fixed regressions
~~~~~~~~~~~~~~~~~
- Fixed regression in taking NULL :class:`objects` from a :class:`DataFrame` causing a segmentation violation. These NULL values are created by :meth:`numpy.empty_like` (:issue:`46848`)
- Fixed regression in :func:`concat` materializing :class:`Index` during sorting even if :class:`Index` was already sorted (:issue:`47501`)
- Fixed regression in :meth:`DataFrame.loc` not updating the cache correctly after values were set (:issue:`47867`)
- Fixed regression in :meth:`DataFrame.loc` not aligning index in some cases when setting a :class:`DataFrame` (:issue:`47578`)
Expand All @@ -36,7 +37,7 @@ Bug fixes

Other
~~~~~
-
- The minimum version of Cython needed to compile pandas is now ``0.29.32`` (:issue:`47978`)
-

.. ---------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ dependencies:
# The compiler packages are meta-packages and install the correct compiler (activation) packages on the respective platforms.
- c-compiler
- cxx-compiler
- cython>=0.29.30
- cython=0.29.32

# code checks
- black=22.3.0
Expand Down
7 changes: 7 additions & 0 deletions pandas/tests/frame/indexing/test_indexing.py
Original file line number Diff line number Diff line change
Expand Up @@ -1227,6 +1227,13 @@ def test_iloc_setitem_nullable_2d_values(self):
df.iloc[:] = df.iloc[:, :]
tm.assert_frame_equal(df, orig)

def test_getitem_segfault_with_empty_like_object(self):
# GH#46848
df = DataFrame(np.empty((1, 1), dtype=object))
df[0] = np.empty_like(df[0])
# this produces the segfault
df[[0]]

@pytest.mark.parametrize(
"null", [pd.NaT, pd.NaT.to_numpy("M8[ns]"), pd.NaT.to_numpy("m8[ns]")]
)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
requires = [
"setuptools>=51.0.0",
"wheel",
"Cython>=0.29.24,<3", # Note: sync with setup.py, environment.yml and asv.conf.json
"Cython>=0.29.32,<3", # Note: sync with setup.py, environment.yml and asv.conf.json
"oldest-supported-numpy>=0.10"
]
# uncomment to enable pep517 after versioneer problem is fixed.
Expand Down
2 changes: 1 addition & 1 deletion requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ numpy>=1.18.5, <=1.22.4
python-dateutil>=2.8.1
pytz
asv
cython>=0.29.30
cython==0.29.32
black==22.3.0
cpplint
flake8==4.0.1
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def is_platform_mac():


# note: sync with pyproject.toml, environment.yml and asv.conf.json
min_cython_ver = "0.29.30"
min_cython_ver = "0.29.32"

try:
from Cython import (
Expand Down