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

DEPR: enforce Series constructor with int dtype deprs #49777

Merged
merged 1 commit into from
Nov 18, 2022

Conversation

jbrockmendel
Copy link
Member

  • 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.

@mroeschke mroeschke added this to the 2.0 milestone Nov 18, 2022
@mroeschke mroeschke added the Deprecate Functionality to remove in pandas label Nov 18, 2022
@mroeschke mroeschke merged commit b01cc53 into pandas-dev:main Nov 18, 2022
@mroeschke
Copy link
Member

Thanks @jbrockmendel

@MarcoGorelli
Copy link
Member

MarcoGorelli commented Dec 21, 2022

the original test fails on 1.5.x with numpy 1.24.0 - we OK to backport?

@mroeschke
Copy link
Member

This would enforce a deprecation early in 1.5 so that would be an API change?

@MarcoGorelli
Copy link
Member

sure, but it's already erroring with numpy 1.24.0

alternatively, do we just pin numpy in the 1.5.x branch and let numpy error? #50384

@mroeschke
Copy link
Member

For maximal backwards compat, users should still be able to use pandas 1.5.3 with numpy < 1.24 and not see an API change while being able to use numpy=1.24.0 and not see failures, but that's a lot of effort I presume

I would be supportive of pinning numpy in the 1.5.x branch and possibly also including an upper pin for numpy in pyproject.toml? Thoughts @pandas-dev/pandas-core

@MarcoGorelli
Copy link
Member

would an upper pin not be pretty limiting, especially on such a widely-used package as numpy, if it's just for the sake of a single test?

@mroeschke
Copy link
Member

mroeschke commented Dec 21, 2022

That's fair, this isn't a showstopping issue.

If users address the pandas deprecation they shouldn't hit the numpy error correct? If so then I would opt to pin numpy on the 1.5.x build

@lithomas1
Copy link
Member

I would prefer not to pin numpy as a whole, since pinning tends to break pip's solver. There's also the risk that pip will just pull the version without the pin.

@jbrockmendel
Copy link
Member Author

would the simplest thing be to just conditionally xfail the affected test?

@MarcoGorelli MarcoGorelli mentioned this pull request Dec 22, 2022
5 tasks
@MarcoGorelli
Copy link
Member

sure, I've gone for that in #50384

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Deprecate Functionality to remove in pandas
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants