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

Fix pandas-nightly #654

Merged
merged 2 commits into from
Apr 20, 2023
Merged

Fix pandas-nightly #654

merged 2 commits into from
Apr 20, 2023

Conversation

twoertwein
Copy link
Member

@twoertwein twoertwein commented Apr 19, 2023

There is still a TypeError on nightly xref pandas-dev/pandas#52790 (will mark as invalid - there is no warning but it will raise in 2.1: I think we should reflect that in our annotations)

@twoertwein twoertwein requested a review from Dr-Irv April 19, 2023 20:12
@twoertwein
Copy link
Member Author

twoertwein commented Apr 20, 2023

Cannot have something like

class PeriodDtype(PandasExtensionDtype):
    @overload
    def __init__(self, freq: CustomBusinessDay) -> Never: ...
    @overload
    def __init__(self, freq: str | BaseOffset = ...) -> None: ...

As mypy then thinks pd.PeriodDtype is not type[ExtensionDtype] anymore. I think that would have wider implications than indicating it is allowed to pass CustomBusinessDay

@Dr-Irv I assume you are busy/on vacation. I will merge this PR and simple PRs like #649 and #650 on Saturday.

@twoertwein twoertwein changed the title Mostly fix pandas-nightly Fix pandas-nightly Apr 20, 2023
Copy link
Collaborator

@Dr-Irv Dr-Irv left a comment

Choose a reason for hiding this comment

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

Thanks @twoertwein . Let's see if it works after the merge.

@Dr-Irv Dr-Irv merged commit 3669013 into pandas-dev:main Apr 20, 2023
@Dr-Irv
Copy link
Collaborator

Dr-Irv commented Apr 20, 2023

Looks like it worked!

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

Successfully merging this pull request may close these issues.

Fix nightly due to a new deprecation in 2.1.x
2 participants