Skip to content

Commit 7ba4a45

Browse files
committed
pre-commit fixes
1 parent e46842a commit 7ba4a45

File tree

3 files changed

+12
-3
lines changed

3 files changed

+12
-3
lines changed

pandas-stubs/core/strings.pyi

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,12 @@ class StringMethods(NoNewAttributesMixin, Generic[T, _TS, _TM, _TS2]):
6969
) -> _TS: ...
7070
@overload
7171
def split(
72-
self, pat: str = ..., *, n: int = ..., expand: Literal[False] = ..., regex: bool = ...
72+
self,
73+
pat: str = ...,
74+
*,
75+
n: int = ...,
76+
expand: Literal[False] = ...,
77+
regex: bool = ...,
7378
) -> _TS2: ...
7479
@overload
7580
def rsplit(self, pat: str = ..., *, n: int = ..., expand: Literal[True]) -> _TS: ...

tests/test_indexes.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,9 @@ def test_str_split() -> None:
114114
check(assert_type(ind.str.split("-"), "pd.Index[list[str]]"), pd.Index)
115115
check(assert_type(ind.str.split("-", expand=True), pd.MultiIndex), pd.MultiIndex)
116116
check(
117-
assert_type(ind.str.split("-", expand=False), "pd.Index[list[str]]"), pd.Index, list
117+
assert_type(ind.str.split("-", expand=False), "pd.Index[list[str]]"),
118+
pd.Index,
119+
list,
118120
)
119121

120122

tests/test_series.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1557,7 +1557,9 @@ def test_string_accessors():
15571557
# GH 194
15581558
check(assert_type(s.str.split("a", expand=True), pd.DataFrame), pd.DataFrame)
15591559
check(
1560-
assert_type(s.str.split("a", expand=False), "pd.Series[list[str]]"), pd.Series, list
1560+
assert_type(s.str.split("a", expand=False), "pd.Series[list[str]]"),
1561+
pd.Series,
1562+
list,
15611563
)
15621564
check(assert_type(s.str.startswith("a"), "pd.Series[bool]"), pd.Series, np.bool_)
15631565
check(

0 commit comments

Comments
 (0)