id,node_id,number,title,user,state,locked,assignee,milestone,comments,created_at,updated_at,closed_at,author_association,active_lock_reason,draft,pull_request,body,reactions,performed_via_github_app,state_reason,repo,type
1552630830,I_kwDOAMm_X85ci0Qu,7467,Many tests fail: AttributeError: 'cftime._cftime.DatetimeJulian' object has no attribute 'daysinmonth',271906,closed,0,,,6,2023-01-23T07:24:40Z,2023-09-26T15:27:42Z,2023-09-26T15:27:42Z,NONE,,,,"### What happened?
There are many failures due to missing 'daysinmonth' attribute:
```
___________________________________________________________________________________ test_infer_freq[360_day-3QS-DEC] ____________________________________________________________________________________
freq = '3QS-DEC', calendar = '360_day'
@requires_cftime
@pytest.mark.parametrize(
""freq"",
[
""300AS-JAN"",
""A-DEC"",
""AS-JUL"",
""2AS-FEB"",
""Q-NOV"",
""3QS-DEC"",
""MS"",
""4M"",
""7D"",
""D"",
""30H"",
""5T"",
""40S"",
],
)
@pytest.mark.parametrize(""calendar"", _CFTIME_CALENDARS)
def test_infer_freq(freq, calendar):
indx = xr.cftime_range(""2000-01-01"", periods=3, freq=freq, calendar=calendar)
> out = xr.infer_freq(indx)
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/tests/test_cftimeindex.py:1334:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:98: in infer_freq
return inferer.get_freq()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:133: in get_freq
return self._infer_daily_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:158: in _infer_daily_rule
quartely_rule = self._get_quartely_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:194: in _get_quartely_rule
return {""cs"": ""QS"", ""ce"": ""Q""}.get(month_anchor_check(self.index))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
dates = <[AttributeError(""'cftime._cftime.Datetime360Day' object has no attribute 'daysinmonth'"") raised in repr()] CFTimeIndex object at 0xc989846a0>
def month_anchor_check(dates):
""""""Return the monthly offset string.
Return ""cs"" if all dates are the first days of the month,
""ce"" if all dates are the last day of the month,
None otherwise.
Replicated pandas._libs.tslibs.resolution.month_position_check
but without business offset handling.
""""""
calendar_end = True
calendar_start = True
for date in dates:
if calendar_start:
calendar_start &= date.day == 1
if calendar_end:
> cal = date.day == date.daysinmonth
E AttributeError: 'cftime._cftime.Datetime360Day' object has no attribute 'daysinmonth'
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:262: AttributeError
____________________________________________________________________________________ test_infer_freq[365_day-A-DEC] _____________________________________________________________________________________
freq = 'A-DEC', calendar = '365_day'
@requires_cftime
@pytest.mark.parametrize(
""freq"",
[
""300AS-JAN"",
""A-DEC"",
""AS-JUL"",
""2AS-FEB"",
""Q-NOV"",
""3QS-DEC"",
""MS"",
""4M"",
""7D"",
""D"",
""30H"",
""5T"",
""40S"",
],
)
@pytest.mark.parametrize(""calendar"", _CFTIME_CALENDARS)
def test_infer_freq(freq, calendar):
indx = xr.cftime_range(""2000-01-01"", periods=3, freq=freq, calendar=calendar)
> out = xr.infer_freq(indx)
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/tests/test_cftimeindex.py:1334:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:98: in infer_freq
return inferer.get_freq()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:133: in get_freq
return self._infer_daily_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:151: in _infer_daily_rule
annual_rule = self._get_annual_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:185: in _get_annual_rule
return {""cs"": ""AS"", ""ce"": ""A""}.get(month_anchor_check(self.index))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
dates = <[AttributeError(""'cftime._cftime.DatetimeNoLeap' object has no attribute 'daysinmonth'"") raised in repr()] CFTimeIndex object at 0xc9b802040>
def month_anchor_check(dates):
""""""Return the monthly offset string.
Return ""cs"" if all dates are the first days of the month,
""ce"" if all dates are the last day of the month,
None otherwise.
Replicated pandas._libs.tslibs.resolution.month_position_check
but without business offset handling.
""""""
calendar_end = True
calendar_start = True
for date in dates:
if calendar_start:
calendar_start &= date.day == 1
if calendar_end:
> cal = date.day == date.daysinmonth
E AttributeError: 'cftime._cftime.DatetimeNoLeap' object has no attribute 'daysinmonth'
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:262: AttributeError
_____________________________________________________________________________________ test_infer_freq[julian-Q-NOV] _____________________________________________________________________________________
freq = 'Q-NOV', calendar = 'julian'
@requires_cftime
@pytest.mark.parametrize(
""freq"",
[
""300AS-JAN"",
""A-DEC"",
""AS-JUL"",
""2AS-FEB"",
""Q-NOV"",
""3QS-DEC"",
""MS"",
""4M"",
""7D"",
""D"",
""30H"",
""5T"",
""40S"",
],
)
@pytest.mark.parametrize(""calendar"", _CFTIME_CALENDARS)
def test_infer_freq(freq, calendar):
indx = xr.cftime_range(""2000-01-01"", periods=3, freq=freq, calendar=calendar)
> out = xr.infer_freq(indx)
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/tests/test_cftimeindex.py:1334:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:98: in infer_freq
return inferer.get_freq()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:133: in get_freq
return self._infer_daily_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:158: in _infer_daily_rule
quartely_rule = self._get_quartely_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:194: in _get_quartely_rule
return {""cs"": ""QS"", ""ce"": ""Q""}.get(month_anchor_check(self.index))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
dates = <[AttributeError(""'cftime._cftime.DatetimeJulian' object has no attribute 'daysinmonth'"") raised in repr()] CFTimeIndex object at 0xc9a4c14c0>
def month_anchor_check(dates):
""""""Return the monthly offset string.
Return ""cs"" if all dates are the first days of the month,
""ce"" if all dates are the last day of the month,
None otherwise.
Replicated pandas._libs.tslibs.resolution.month_position_check
but without business offset handling.
""""""
calendar_end = True
calendar_start = True
for date in dates:
if calendar_start:
calendar_start &= date.day == 1
if calendar_end:
> cal = date.day == date.daysinmonth
E AttributeError: 'cftime._cftime.DatetimeJulian' object has no attribute 'daysinmonth'
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:262: AttributeError
_____________________________________________________________________________________ test_infer_freq[all_leap-MS] ______________________________________________________________________________________
freq = 'MS', calendar = 'all_leap'
@requires_cftime
@pytest.mark.parametrize(
""freq"",
[
""300AS-JAN"",
""A-DEC"",
""AS-JUL"",
""2AS-FEB"",
""Q-NOV"",
""3QS-DEC"",
""MS"",
""4M"",
""7D"",
""D"",
""30H"",
""5T"",
""40S"",
],
)
@pytest.mark.parametrize(""calendar"", _CFTIME_CALENDARS)
def test_infer_freq(freq, calendar):
indx = xr.cftime_range(""2000-01-01"", periods=3, freq=freq, calendar=calendar)
> out = xr.infer_freq(indx)
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/tests/test_cftimeindex.py:1334:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:98: in infer_freq
return inferer.get_freq()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:133: in get_freq
return self._infer_daily_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:166: in _infer_daily_rule
monthly_rule = self._get_monthly_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:200: in _get_monthly_rule
return {""cs"": ""MS"", ""ce"": ""M""}.get(month_anchor_check(self.index))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
dates = <[AttributeError(""'cftime._cftime.DatetimeAllLeap' object has no attribute 'daysinmonth'"") raised in repr()] CFTimeIndex object at 0xc9b8022b0>
def month_anchor_check(dates):
""""""Return the monthly offset string.
Return ""cs"" if all dates are the first days of the month,
""ce"" if all dates are the last day of the month,
None otherwise.
Replicated pandas._libs.tslibs.resolution.month_position_check
but without business offset handling.
""""""
calendar_end = True
calendar_start = True
for date in dates:
if calendar_start:
calendar_start &= date.day == 1
if calendar_end:
> cal = date.day == date.daysinmonth
E AttributeError: 'cftime._cftime.DatetimeAllLeap' object has no attribute 'daysinmonth'
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:262: AttributeError
_____________________________________________________________________________ test_cftimeindex_calendar_repr[julian-julian] _____________________________________________________________________________
calendar = 'julian', expected = 'julian'
@requires_cftime
@pytest.mark.parametrize(
(""calendar"", ""expected""),
[
(""noleap"", ""noleap""),
(""365_day"", ""noleap""),
(""360_day"", ""360_day""),
(""julian"", ""julian""),
(""gregorian"", standard_or_gregorian),
(""standard"", standard_or_gregorian),
(""proleptic_gregorian"", ""proleptic_gregorian""),
],
)
def test_cftimeindex_calendar_repr(calendar, expected):
""""""Test that cftimeindex has calendar property in repr.""""""
index = xr.cftime_range(start=""2000"", periods=3, calendar=calendar)
> repr_str = index.__repr__()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/tests/test_cftimeindex.py:1012:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/cftimeindex.py:356: in __repr__
attrs_str = format_attrs(self)
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/cftimeindex.py:276: in format_attrs
""freq"": f""'{index.freq}'"" if len(index) >= 3 else None,
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/cftimeindex.py:708: in freq
return infer_freq(self)
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:98: in infer_freq
return inferer.get_freq()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:133: in get_freq
return self._infer_daily_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:151: in _infer_daily_rule
annual_rule = self._get_annual_rule()
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:185: in _get_annual_rule
return {""cs"": ""AS"", ""ce"": ""A""}.get(month_anchor_check(self.index))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
dates = <[AttributeError(""'cftime._cftime.DatetimeJulian' object has no attribute 'daysinmonth'"") raised in repr()] CFTimeIndex object at 0xc9a4d6e50>
def month_anchor_check(dates):
""""""Return the monthly offset string.
Return ""cs"" if all dates are the first days of the month,
""ce"" if all dates are the last day of the month,
None otherwise.
Replicated pandas._libs.tslibs.resolution.month_position_check
but without business offset handling.
""""""
calendar_end = True
calendar_start = True
for date in dates:
if calendar_start:
calendar_start &= date.day == 1
if calendar_end:
> cal = date.day == date.daysinmonth
E AttributeError: 'cftime._cftime.DatetimeJulian' object has no attribute 'daysinmonth'
/usr/ports/devel/py-xarray/work-py39/xarray-2023.1.0/xarray/coding/frequencies.py:262: AttributeError
```
Version: 2023.1.0
Python-3.9
FreeBSD 13.1
### What did you expect to happen?
_No response_
### Minimal Complete Verifiable Example
_No response_
### MVCE confirmation
- [X] Minimal example — the example is as focused as reasonably possible to demonstrate the underlying issue in xarray.
- [X] Complete example — the example is self-contained, including all data and the text of any traceback.
- [X] Verifiable example — the example copy & pastes into an IPython prompt or [Binder notebook](https://mybinder.org/v2/gh/pydata/xarray/main?urlpath=lab/tree/doc/examples/blank_template.ipynb), returning the result.
- [X] New issue — a search of GitHub Issues suggests this is not a duplicate.
### Relevant log output
_No response_
### Anything else we need to know?
_No response_
### Environment
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/7467/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue
1630998880,I_kwDOAMm_X85hNxFg,7646,Tests fail to run: SystemError: initialization of _internal failed without raising an exception,271906,closed,0,,,2,2023-03-19T15:56:13Z,2023-04-06T01:57:33Z,2023-04-06T01:57:33Z,NONE,,,,"### What happened?
```
================================================================================================ ERRORS =================================================================================================
_____________________________________________________________________________________ ERROR collecting test session _____________________________________________________________________________________
/usr/local/lib/python3.9/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
:1030: in _gcd_import
???
:1007: in _find_and_load
???
:972: in _find_and_load_unlocked
???
:228: in _call_with_frames_removed
???
:1030: in _gcd_import
???
:1007: in _find_and_load
???
:986: in _find_and_load_unlocked
???
:680: in _load_unlocked
???
:850: in exec_module
???
:228: in _call_with_frames_removed
???
xarray/tests/__init__.py:79: in
has_sparse, requires_sparse = _importorskip(""sparse"")
xarray/tests/__init__.py:51: in _importorskip
mod = importlib.import_module(modname)
/usr/local/lib/python3.9/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
:1030: in _gcd_import
???
:1007: in _find_and_load
???
:986: in _find_and_load_unlocked
???
:680: in _load_unlocked
???
:850: in exec_module
???
:228: in _call_with_frames_removed
???
/usr/local/lib/python3.9/site-packages/sparse/__init__.py:1: in
from ._coo import COO, as_coo
/usr/local/lib/python3.9/site-packages/sparse/_coo/__init__.py:1: in
from .core import COO, as_coo
/usr/local/lib/python3.9/site-packages/sparse/_coo/core.py:9: in
import numba
/usr/local/lib/python3.9/site-packages/numba/__init__.py:42: in
from numba.np.ufunc import (vectorize, guvectorize, threading_layer,
/usr/local/lib/python3.9/site-packages/numba/np/ufunc/__init__.py:3: in
from numba.np.ufunc.decorators import Vectorize, GUVectorize, vectorize, guvectorize
/usr/local/lib/python3.9/site-packages/numba/np/ufunc/decorators.py:3: in
from numba.np.ufunc import _internal
E SystemError: initialization of _internal failed without raising an exception
=========================================================================================== warnings summary ============================================================================================
../../../../../local/lib/python3.9/site-packages/matplotlib/__init__.py:152
../../../../../local/lib/python3.9/site-packages/matplotlib/__init__.py:152
../../../../../local/lib/python3.9/site-packages/matplotlib/__init__.py:152
../../../../../local/lib/python3.9/site-packages/matplotlib/__init__.py:152
../../../../../local/lib/python3.9/site-packages/matplotlib/__init__.py:152
/usr/local/lib/python3.9/site-packages/matplotlib/__init__.py:152: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(module.__version__) < minver:
../../../../../local/lib/python3.9/site-packages/setuptools/_distutils/version.py:346
../../../../../local/lib/python3.9/site-packages/setuptools/_distutils/version.py:346
../../../../../local/lib/python3.9/site-packages/setuptools/_distutils/version.py:346
../../../../../local/lib/python3.9/site-packages/setuptools/_distutils/version.py:346
../../../../../local/lib/python3.9/site-packages/setuptools/_distutils/version.py:346
../../../../../local/lib/python3.9/site-packages/setuptools/_distutils/version.py:346
/usr/local/lib/python3.9/site-packages/setuptools/_distutils/version.py:346: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
other = LooseVersion(other)
../../../../../local/lib/python3.9/site-packages/seaborn/rcmod.py:82
/usr/local/lib/python3.9/site-packages/seaborn/rcmod.py:82: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(mpl.__version__) >= ""3.0"":
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
===================================================================================== 12 warnings, 1 error in 3.76s =====================================================================================
```
Version: 2023.2.0
### What did you expect to happen?
_No response_
### Minimal Complete Verifiable Example
_No response_
### MVCE confirmation
- [ ] Minimal example — the example is as focused as reasonably possible to demonstrate the underlying issue in xarray.
- [ ] Complete example — the example is self-contained, including all data and the text of any traceback.
- [ ] Verifiable example — the example copy & pastes into an IPython prompt or [Binder notebook](https://mybinder.org/v2/gh/pydata/xarray/main?urlpath=lab/tree/doc/examples/blank_template.ipynb), returning the result.
- [ ] New issue — a search of GitHub Issues suggests this is not a duplicate.
### Relevant log output
_No response_
### Anything else we need to know?
_No response_
### Environment
FreeBSD port","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/7646/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue