You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The stubs for pandas_stubs.core.strings.StringMethods.split do not return pandas.Series[list[str]] type with expand=False parameter for Series/Index containing lists of strings as described in docs.
Type "list[str]" cannot be assigned to type variable "S1@Series"
Type "list[str]" is not assignable to upper bound "Dtype | bytes | date | time | bool | int | float | complex | datetime | timedelta | Period | Interval[Unknown] | CategoricalDtype | BaseOffset" for type variable "S1@Series"
Type "list[str]" is not assignable to type "Dtype | bytes | date | time | bool | int | float | complex | datetime | timedelta | Period | Interval[Unknown] | CategoricalDtype | BaseOffset"
"list[str]" is not assignable to "str"
"list[str]" is not assignable to "bytes"
"list[str]" is not assignable to "date"
"list[str]" is not assignable to "time"
"list[str]" is not assignable to "bool"
"list[str]" is not assignable to "int"
...PylancereportInvalidTypeArguments
The following is type of "Series[Unknown]":
frompandasimportSeriess=Series(["one", "two"])
s=s.str.split(expand=False)
reveal_type(s) # Type of "s" is "Series[Unknown]"
Please complete the following information:
OS : MacOS
OS Version : Sonoma 14.7.1
python : 3.10.14
processor : arm64
VS Code : 1.96.0 (Universal)
pandas : 2.2.3
pandas-stubs : 2.2.3.241126
Pylance : 2024.12.1
The text was updated successfully, but these errors were encountered:
Describe the bug
The stubs for
pandas_stubs.core.strings.StringMethods.split
do not returnpandas.Series[list[str]]
type withexpand=False
parameter for Series/Index containing lists of strings as described in docs.To Reproduce
Use VS Code with Pylance extension:
Please complete the following information:
The text was updated successfully, but these errors were encountered: