Skip to content

Commit 5c7abca

Browse files
authored
Add TODO note to BlockManager.fast_xs for EA dtypes (#55039)
1 parent 3334832 commit 5c7abca

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pandas/core/internals/managers.py

+4
Original file line numberDiff line numberDiff line change
@@ -969,6 +969,10 @@ def fast_xs(self, loc: int) -> SingleBlockManager:
969969
n = len(self)
970970

971971
if isinstance(dtype, ExtensionDtype):
972+
# TODO: use object dtype as workaround for non-performant
973+
# EA.__setitem__ methods. (primarily ArrowExtensionArray.__setitem__
974+
# when iteratively setting individual values)
975+
# https://github.com/pandas-dev/pandas/pull/54508#issuecomment-1675827918
972976
result = np.empty(n, dtype=object)
973977
else:
974978
result = np.empty(n, dtype=dtype)

0 commit comments

Comments
 (0)