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/4275#issuecomment-1102343409,https://api.github.com/repos/pydata/xarray/issues/4275,1102343409,IC_kwDOAMm_X85BtGzx,31126826,2022-04-19T09:02:57Z,2022-04-19T09:02:57Z,CONTRIBUTOR,"No worry, I had actually forgotten about this. In a more recent version (`2022.3.0`), both 1D and 2D case return the same `ValueError` with a relatively clear message `x and y arrays must have at least 2 entries`. I'm still proposing that any valid code with `sel` should behave the same with `interp`, and thus that `interp` should work when a dimension has a single entry. But this is a low priority issue with easy workarounds.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,666270493 https://github.com/pydata/xarray/pull/3976#issuecomment-615256103,https://api.github.com/repos/pydata/xarray/issues/3976,615256103,MDEyOklzc3VlQ29tbWVudDYxNTI1NjEwMw==,31126826,2020-04-17T13:51:50Z,2020-04-17T13:52:05Z,CONTRIBUTOR,"Thank you for your comments @shoyer I agree with all of them and have updated the code.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,601185984 https://github.com/pydata/xarray/issues/3910#issuecomment-614146417,https://api.github.com/repos/pydata/xarray/issues/3910,614146417,MDEyOklzc3VlQ29tbWVudDYxNDE0NjQxNw==,31126826,2020-04-15T16:35:46Z,2020-04-15T16:35:46Z,CONTRIBUTOR,"Well actually, I would be at least as surprised if `A += B` returned a different result than `A = A + B`. So now I understand why this is not supported. I'll submit the PR soon.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,589632313 https://github.com/pydata/xarray/issues/3910#issuecomment-606100412,https://api.github.com/repos/pydata/xarray/issues/3910,606100412,MDEyOklzc3VlQ29tbWVudDYwNjEwMDQxMg==,31126826,2020-03-30T16:22:04Z,2020-03-30T16:22:04Z,CONTRIBUTOR,"Yes. But the not-in-place addition `A+B` works fine without conversion to float because it uses basically `xr.align(A, B, join='inner')`. If the in-place addition did the same, there would be no risk of type conversion. But I guess the in-place version would rather use something like `xr.align(A, B, join='left')` to guarantee that the shape and index of `A` does not change. Am I right?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,589632313 https://github.com/pydata/xarray/issues/3910#issuecomment-605847162,https://api.github.com/repos/pydata/xarray/issues/3910,605847162,MDEyOklzc3VlQ29tbWVudDYwNTg0NzE2Mg==,31126826,2020-03-30T08:06:32Z,2020-03-30T08:06:32Z,CONTRIBUTOR,"I can submit a PR. But the comment cited above is not totally clear to me. The purpose of the conversion to floats is to have NaNs in case the shapes do not match. So the core of the issue is that A + B might not have the same shape as A, and thus in general A + B cannot replace A in-place. Is that right? ","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,589632313 https://github.com/pydata/xarray/issues/3674#issuecomment-598718876,https://api.github.com/repos/pydata/xarray/issues/3674,598718876,MDEyOklzc3VlQ29tbWVudDU5ODcxODg3Ng==,31126826,2020-03-13T13:26:38Z,2020-03-13T13:26:38Z,CONTRIBUTOR,"Yes, I'll give it a try.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,547091670 https://github.com/pydata/xarray/issues/3674#issuecomment-597536240,https://api.github.com/repos/pydata/xarray/issues/3674,597536240,MDEyOklzc3VlQ29tbWVudDU5NzUzNjI0MA==,31126826,2020-03-11T09:44:48Z,2020-03-11T09:44:48Z,CONTRIBUTOR,"@fujiisoup Since you implemented `remove_unused_levels_categories`, do you have any clue how to fix this?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,547091670 https://github.com/pydata/xarray/issues/3674#issuecomment-583065626,https://api.github.com/repos/pydata/xarray/issues/3674,583065626,MDEyOklzc3VlQ29tbWVudDU4MzA2NTYyNg==,31126826,2020-02-06T19:17:49Z,2020-02-06T19:17:49Z,CONTRIBUTOR,"Actually, after updating to version 0.15 I've found another issue in the same context. More precisely, when using a multi-index with a non-categorical repeated coordinate and a categorical coordinate: ```python import pandas as pd i1 = pd.Series([0, 0]) cat = pd.CategoricalDtype(categories=['foo', 'bar', 'baz']) i2 = pd.Series(['foo', 'bar'], dtype=cat) df = pd.DataFrame({'i1': i1, 'i2': i2, 'values': [1, 2]}) ds = df.set_index(['i1', 'i2']).to_xarray() print(ds) ``` raises the following error ``` Traceback (most recent call last): File ""/home/matthieu/test.py"", line 8, in ds = df.set_index(['i1', 'i2']).to_xarray() File ""/opt/anaconda3/lib/python3.7/site-packages/pandas/core/generic.py"", line 2867, in to_xarray return xarray.Dataset.from_dataframe(self) File ""/opt/anaconda3/lib/python3.7/site-packages/xarray/core/dataset.py"", line 4555, in from_dataframe idx = remove_unused_levels_categories(dataframe.index) File ""/opt/anaconda3/lib/python3.7/site-packages/xarray/core/indexes.py"", line 26, in remove_unused_levels_ categories index = pd.MultiIndex.from_arrays(levels, names=index.names) File ""/opt/anaconda3/lib/python3.7/site-packages/pandas/core/indexes/multi.py"", line 425, in from_arrays raise ValueError(""all arrays must be same length"") ValueError: all arrays must be same length ``` but works fine when `i2` is not categorical.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,547091670 https://github.com/pydata/xarray/issues/3674#issuecomment-579379370,https://api.github.com/repos/pydata/xarray/issues/3674,579379370,MDEyOklzc3VlQ29tbWVudDU3OTM3OTM3MA==,31126826,2020-01-28T18:04:32Z,2020-01-28T18:04:32Z,CONTRIBUTOR,"Thank you for your work on this! I haven't found any other issue at the moment, I guess we can close this issue.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,547091670 https://github.com/pydata/xarray/issues/3669#issuecomment-572248703,https://api.github.com/repos/pydata/xarray/issues/3669,572248703,MDEyOklzc3VlQ29tbWVudDU3MjI0ODcwMw==,31126826,2020-01-08T20:44:04Z,2020-01-08T20:44:04Z,CONTRIBUTOR,"Your patch fixes the issue, thank you! FYI, found another issue with categorical values: #3674","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,546727720