From 014e7cf9d6871848cc1345cb2e7fa5814426874f Mon Sep 17 00:00:00 2001 From: Anderson Banihirwe Date: Thu, 31 Oct 2024 18:56:56 -0700 Subject: [PATCH] remove unnecessary copy argument from __array__ method in MemoryCachedArray --- xarray/core/indexing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xarray/core/indexing.py b/xarray/core/indexing.py index 86e747aedc4..1447f00df05 100644 --- a/xarray/core/indexing.py +++ b/xarray/core/indexing.py @@ -863,7 +863,7 @@ def _ensure_cached(self): def __array__( self, dtype: np.typing.DTypeLike = None, /, *, copy: bool | None = None ) -> np.ndarray: - return np.asarray(self.get_duck_array(), dtype=dtype, copy=copy) + return np.asarray(self.get_duck_array(), dtype=dtype) def get_duck_array(self): self._ensure_cached()