Skip to content
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

ENH: Fix Python 3.13 test failures & enable CI #59065

Merged
merged 3 commits into from
Jun 25, 2024

Conversation

lysnikolaou
Copy link
Contributor

x-ref #58734

  • closes #xxxx (Replace xxxx with the GitHub issue number)
  • Tests added and passed if fixing a bug or adding a new feature
  • All code checks passed.
  • Added type annotations to new arguments/methods/functions.
  • Added an entry in the latest doc/source/whatsnew/vX.X.X.rst file if fixing a bug or adding a new feature.

x-ref pandas-dev#58734

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>
@lysnikolaou
Copy link
Contributor Author

@lithomas1 python-dev CI seems to be passing on all platforms. Pyarrow Nightly and Unit Tests / Linux-32-bit are failing but it appears that they also fail on main. Is this good to go?

@lithomas1 lithomas1 added the CI Continuous Integration label Jun 23, 2024
@lithomas1 lithomas1 added this to the 3.0 milestone Jun 23, 2024
if is_period and not hasattr(result, "_period_dtype_code"):
try:
has_period_dtype_code = hasattr(result, "_period_dtype_code")
except ValueError:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the error here?

Copy link
Contributor Author

@lysnikolaou lysnikolaou Jun 23, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error is that the _period_dtype_code property raises ValueError in CustomBusinessDay. In 3.12 and older, Cython was silently ignoring exceptions and hasattr was returning False. In 3.13 the exception is not ignored anymore. More info on cython/cython#6251 (comment).

@lysnikolaou lysnikolaou marked this pull request as ready for review June 24, 2024 16:16
@lysnikolaou
Copy link
Contributor Author

I'm marking as ready for review, since I don't think there's any more outstanding issues for 3.13.

Copy link
Member

@lithomas1 lithomas1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This LGTM pending green.

Thanks for picking this up!

@mroeschke mroeschke merged commit 39a3bf3 into pandas-dev:main Jun 25, 2024
44 checks passed
@mroeschke
Copy link
Member

Thanks @lysnikolaou and @lithomas1

WillAyd pushed a commit to WillAyd/pandas that referenced this pull request Aug 15, 2024
* ENH: Fix Python 3.13 test failures & enable CI

x-ref pandas-dev#58734

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>

* Cast npy_intp to int to fix Windows CI

---------

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>
@jorisvandenbossche jorisvandenbossche modified the milestones: 3.0, 2.2.3 Aug 20, 2024
WillAyd pushed a commit to WillAyd/pandas that referenced this pull request Aug 22, 2024
* ENH: Fix Python 3.13 test failures & enable CI

x-ref pandas-dev#58734

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>

* Cast npy_intp to int to fix Windows CI

---------

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>
WillAyd pushed a commit to WillAyd/pandas that referenced this pull request Aug 22, 2024
* ENH: Fix Python 3.13 test failures & enable CI

x-ref pandas-dev#58734

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>

* Cast npy_intp to int to fix Windows CI

---------

Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>
@lithomas1
Copy link
Member

@meeseeksdev backport 2.2.x

Copy link

lumberbot-app bot commented Sep 12, 2024

Owee, I'm MrMeeseeks, Look at me.

There seem to be a conflict, please backport manually. Here are approximate instructions:

  1. Checkout backport branch and update it.
git checkout 2.2.x
git pull
  1. Cherry pick the first parent branch of the this PR on top of the older branch:
git cherry-pick -x -m1 39a3bf355574df76df44cededffac96fddb48a04
  1. You will likely have some merge/cherry-pick conflict here, fix them and commit:
git commit -am 'Backport PR #59065: ENH: Fix Python 3.13 test failures & enable CI'
  1. Push to a named branch:
git push YOURFORK 2.2.x:auto-backport-of-pr-59065-on-2.2.x
  1. Create a PR against branch 2.2.x, I would have named this PR:

"Backport PR #59065 on branch 2.2.x (ENH: Fix Python 3.13 test failures & enable CI)"

And apply the correct labels and milestones.

Congratulations — you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon!

Remember to remove the Still Needs Manual Backport label once the PR gets merged.

If these instructions are inaccurate, feel free to suggest an improvement.

lithomas1 pushed a commit to lithomas1/pandas that referenced this pull request Sep 12, 2024
lithomas1 added a commit that referenced this pull request Sep 18, 2024
* Backport PR #59065: ENH: Fix Python 3.13 test failures & enable CI

* Remove deprecated plot_date calls (#58484)

* Remove deprecated plot_date calls

These were deprecated in Matplotlib 3.9.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
(cherry picked from commit c9bc480)

* Pick out fastparquet xfails for green CI

* pin pytz to fix test_arrays.py

* more workflow tweaks for pytz and Python 3.13

* fix typing and tune tests for copy on write

* remove WASM stuff

* more arm skips

* go for green

---------

Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants