Skip to content

REF: get rid of ArrowStringArrayNumpySemantics #62165

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
Aug 22, 2025

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.

analogous to #62149


if dtype is None:
dtype = StringDtype(storage="pyarrow", na_value=libmissing.NA)
self._dtype = dtype
Copy link
Member

Choose a reason for hiding this comment

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

Worth raising if dtype.storage != "pyarrow"?

Copy link
Member

Choose a reason for hiding this comment

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

Or should __init__ only accept na_value: libmissing.NAType | np.nan = libmissing.NA?

Copy link
Member Author

Choose a reason for hiding this comment

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

I think accepting dtype is more idiomatic. I’d be ok with adding that check but don’t think it necessary

@mroeschke mroeschke added the Refactor Internal refactoring of code label Aug 22, 2025
@mroeschke mroeschke added this to the 3.0 milestone Aug 22, 2025
@mroeschke mroeschke merged commit f84ba18 into pandas-dev:main Aug 22, 2025
42 checks passed
@mroeschke
Copy link
Member

Thanks @jbrockmendel

@jbrockmendel jbrockmendel deleted the ref-fewer-strings-pa branch August 22, 2025 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactor Internal refactoring of code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants