html_url,issue_url,id,node_id,user,created_at,updated_at,author_association,body,reactions,performed_via_github_app,issue https://github.com/pydata/xarray/issues/6524#issuecomment-1146873595,https://api.github.com/repos/pydata/xarray/issues/6524,1146873595,IC_kwDOAMm_X85EW-b7,1217238,2022-06-05T19:54:47Z,2022-06-05T19:54:47Z,MEMBER,"> ``` > error: ""ndarray[Any, dtype[Any]]"" has no attribute ""rename"" > ``` Yes, it's worth discussing. I don't know if there will be a satisfying resolution, though.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,1217425815 https://github.com/pydata/xarray/issues/6524#issuecomment-1111813044,https://api.github.com/repos/pydata/xarray/issues/6524,1111813044,IC_kwDOAMm_X85CROu0,1217238,2022-04-28T06:52:04Z,2022-04-28T06:52:04Z,MEMBER,"I think this would need to get updated on the NumPy side. Ideally NumPy ufuncs would be typed to check for `__array_ufunc__`. Something like: ```python from typing import Protocol, TypeVar class HasArrayUFunc(Protocol): def __array_ufunc__(ufunc, method, *inputs, **kwargs): pass ArrayOrHasArrayUFunc = TypeVar(""ArrayOrHasArrayUFunc"", ndarray, HasArrayUFunc) def exp(x: ArrayOrHasArrayUFunc) -> ArrayOrHasArrayUFunc: ... ```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,1217425815 https://github.com/pydata/xarray/issues/6524#issuecomment-1111671741,https://api.github.com/repos/pydata/xarray/issues/6524,1111671741,IC_kwDOAMm_X85CQsO9,5635139,2022-04-28T02:26:07Z,2022-04-28T02:26:07Z,MEMBER,"Thanks, I see the same thing re pandas. It makes me think it may be coming from xarray, since it's not just `np.exp(series).rename(""blah"")` which is raising. But I'm not sure _where_ it would be coming from. Our `__array_ufunc__` isn't typed...!","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,1217425815 https://github.com/pydata/xarray/issues/6524#issuecomment-1111436375,https://api.github.com/repos/pydata/xarray/issues/6524,1111436375,IC_kwDOAMm_X85CPyxX,5635139,2022-04-27T20:12:35Z,2022-04-27T20:13:08Z,MEMBER,"Thanks for the issue @milliams . My guess is that the `""ndarray[Any, dtype[Any]]""` type signature is from `np.exp`. Do you know whether we get the same result with another library's `__array_ufunc__`'s arrays, with that library's equivalent `rename` method?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,1217425815