Skip to content

Conversation

@caneff
Copy link
Contributor

@caneff caneff commented Sep 4, 2023

This adds overloads so that a type checker can determine whether clip returns a Series/DataFrame or None based on the value of the inplace argument.

This adds overloads so that a type checker can determine whether clip returns a  Series/DataFrame or None based on the value of the inplace argument.
@caneff
Copy link
Contributor Author

caneff commented Sep 4, 2023

pre-commit.ci autofix

Copy link
Member

@twoertwein twoertwein left a comment

Choose a reason for hiding this comment

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

LGTM assuming mypy/pyright pass

@twoertwein twoertwein merged commit e30e5f8 into pandas-dev:main Sep 4, 2023
@twoertwein
Copy link
Member

Thank you @caneff !

@caneff
Copy link
Contributor Author

caneff commented Sep 4, 2023 via email

@caneff caneff deleted the caneff-patch-1 branch September 4, 2023 19:05
mroeschke pushed a commit to mroeschke/pandas that referenced this pull request Sep 11, 2023
…dev#55002)

* TYP: Add typing.overload signatures to DataFrame/Series.clip

This adds overloads so that a type checker can determine whether clip returns a  Series/DataFrame or None based on the value of the inplace argument.

* [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>
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.

2 participants