You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If join='exact', raise an error for non-aligned objects (#1330)
* If join='exact', raise an error for non-aligned objects
`align` now supports ``join='exact'``, which raises `xarray.AlignmentError`
instead of aligning when indexes to be aligned are not equal.
This is useful for asserting that objects are identical instead of aligning in
xarray operations.
For example:
ds1 = xarray.Dataset({'x': [0, 1]})
ds2 = xarray.Dataset({'x': [1, 2]})
xarray.merge([ds1, ds2], join='exact')
# AlignmentError: indexes along dimension 'x' are not equal
* Switch AlignmentError -> ValueError
* What's new fix
0 commit comments