|
31 | 31 | config, |
32 | 32 | get_option, |
33 | 33 | using_copy_on_write, |
34 | | - using_pyarrow_string_dtype, |
| 34 | + using_string_dtype, |
35 | 35 | ) |
36 | 36 |
|
37 | 37 | from pandas._libs import ( |
@@ -3224,7 +3224,7 @@ def read( |
3224 | 3224 | index = self.read_index("index", start=start, stop=stop) |
3225 | 3225 | values = self.read_array("values", start=start, stop=stop) |
3226 | 3226 | result = Series(values, index=index, name=self.name, copy=False) |
3227 | | - if using_pyarrow_string_dtype() and is_string_array(values, skipna=True): |
| 3227 | + if using_string_dtype() and is_string_array(values, skipna=True): |
3228 | 3228 | result = result.astype("string[pyarrow_numpy]") |
3229 | 3229 | return result |
3230 | 3230 |
|
@@ -3293,7 +3293,7 @@ def read( |
3293 | 3293 |
|
3294 | 3294 | columns = items[items.get_indexer(blk_items)] |
3295 | 3295 | df = DataFrame(values.T, columns=columns, index=axes[1], copy=False) |
3296 | | - if using_pyarrow_string_dtype() and is_string_array(values, skipna=True): |
| 3296 | + if using_string_dtype() and is_string_array(values, skipna=True): |
3297 | 3297 | df = df.astype("string[pyarrow_numpy]") |
3298 | 3298 | dfs.append(df) |
3299 | 3299 |
|
@@ -4679,9 +4679,9 @@ def read( |
4679 | 4679 | else: |
4680 | 4680 | # Categorical |
4681 | 4681 | df = DataFrame._from_arrays([values], columns=cols_, index=index_) |
4682 | | - if not (using_pyarrow_string_dtype() and values.dtype.kind == "O"): |
| 4682 | + if not (using_string_dtype() and values.dtype.kind == "O"): |
4683 | 4683 | assert (df.dtypes == values.dtype).all(), (df.dtypes, values.dtype) |
4684 | | - if using_pyarrow_string_dtype() and is_string_array( |
| 4684 | + if using_string_dtype() and is_string_array( |
4685 | 4685 | values, # type: ignore[arg-type] |
4686 | 4686 | skipna=True, |
4687 | 4687 | ): |
|
0 commit comments