Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions xarray/namedarray/_typing.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
from collections.abc import Hashable, Iterable, Mapping, Sequence
from types import ModuleType
from typing import (
TYPE_CHECKING,
Any,
Callable,
Protocol,
Expand All @@ -16,10 +15,6 @@

import numpy as np

if TYPE_CHECKING:
from numpy.typing import NDArray


# https://stackoverflow.com/questions/74633074/how-to-type-hint-a-generic-numpy-array
_T = TypeVar("_T")
_T_co = TypeVar("_T_co", covariant=True)
Expand Down Expand Up @@ -234,7 +229,7 @@ class _sparsearray(
Corresponds to np.ndarray.
"""

def todense(self) -> NDArray[_ScalarType_co]:
def todense(self) -> np.ndarray[Any, _DType_co]:
...


Expand Down