From df4ea687fefa6ce29dd2f8f11abb134e8bb239fa Mon Sep 17 00:00:00 2001 From: Keewis Date: Fri, 21 Feb 2020 15:19:38 +0100 Subject: [PATCH] make sure we actually decide based on dask.array.Array --- xarray/core/duck_array_ops.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xarray/core/duck_array_ops.py b/xarray/core/duck_array_ops.py index 6a9f93bb311..20a9c91637d 100644 --- a/xarray/core/duck_array_ops.py +++ b/xarray/core/duck_array_ops.py @@ -72,7 +72,7 @@ def fail_on_dask_array_input(values, msg=None, func_name=None): if hasattr(np, "isnat") and ( - dask_array is None or hasattr(dask_array_type, "__array_ufunc__") + dask_array_type == () or hasattr(dask_array_type[0], "__array_ufunc__") ): # np.isnat is available since NumPy 1.13, so __array_ufunc__ is always # supported.