1616 from narwhals ._compliant .namespace import CompliantNamespace # noqa: F401
1717 from narwhals ._compliant .namespace import EagerNamespace
1818 from narwhals .dtypes import DType
19+ from narwhals .typing import Into1DArray
1920 from narwhals .typing import NativeSeries
20- from narwhals .typing import _1DArray
21- from narwhals .typing import _NumpyScalar
21+ from narwhals .typing import _1DArray # noqa: F401
2222 from narwhals .utils import Implementation
2323 from narwhals .utils import Version
2424 from narwhals .utils import _FullContext
2828NativeSeriesT_co = TypeVar ("NativeSeriesT_co" , bound = "NativeSeries" , covariant = True )
2929
3030
31- class CompliantSeries (NumpyConvertible ["_1DArray" , "_1DArray | _NumpyScalar " ], Protocol ):
31+ class CompliantSeries (NumpyConvertible ["_1DArray" , "Into1DArray " ], Protocol ):
3232 @property
3333 def dtype (self ) -> DType : ...
3434 @property
@@ -41,9 +41,7 @@ def __narwhals_namespace__(self) -> Any: ... # CompliantNamespace[Any, Self]: .
4141 def _from_native_series (self , series : Any ) -> Self : ...
4242 def _to_expr (self ) -> Any : ... # CompliantExpr[Any, Self]: ...
4343 @classmethod
44- def from_numpy (
45- cls , data : _1DArray | _NumpyScalar , / , * , context : _FullContext
46- ) -> Self : ...
44+ def from_numpy (cls , data : Into1DArray , / , * , context : _FullContext ) -> Self : ...
4745
4846
4947class EagerSeries (CompliantSeries , Protocol [NativeSeriesT_co ]):
0 commit comments