Skip to content

TYP: SparseArray #43513

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 2 commits into from
Sep 12, 2021
Merged

TYP: SparseArray #43513

merged 2 commits into from
Sep 12, 2021

Conversation

mzeitlin11
Copy link
Member

No description provided.

@mzeitlin11 mzeitlin11 added Sparse Sparse Data Type Typing type annotations, mypy/pyright type checking labels Sep 11, 2021
else:
# error: Incompatible types in assignment (expression has type
# "Union[ndarray, SparseArray]", variable has type "ndarray")
result = self._take_without_fill(indices) # type: ignore[assignment]
kwargs = {"dtype": self.dtype}
dtype = self.dtype
Copy link
Member Author

Choose a reason for hiding this comment

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

Avoiding kwargs here since mypy will complain about multiple different types in kwargs. Since only using dtype, seems fine to just pass that

@jreback jreback added this to the 1.4 milestone Sep 12, 2021
@jreback jreback merged commit 1c6c767 into pandas-dev:master Sep 12, 2021
@jreback
Copy link
Contributor

jreback commented Sep 12, 2021

thanks @mzeitlin11

@mzeitlin11 mzeitlin11 deleted the typ_sparse branch September 12, 2021 15:11
AlexeyGy pushed a commit to AlexeyGy/pandas that referenced this pull request Sep 13, 2021
AlexeyGy pushed a commit to AlexeyGy/pandas that referenced this pull request Sep 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Sparse Sparse Data Type Typing type annotations, mypy/pyright type checking
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants