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
1537068105,I_kwDOAMm_X85bncxJ,7450,Backend array documentation typo,14371165,open,0,,,0,2023-01-17T21:37:26Z,2023-01-17T21:56:12Z,,MEMBER,,,,"### What happened?
https://docs.xarray.dev/en/stable/internals/how-to-add-new-backend.html#indexing-examples
I believe there's a typo in the BASIC indexing support example:
```python
# shall support integers
backend_array._raw_indexing_method(1, 1)
```
Should be:
```python
# shall support integers
backend_array._raw_indexing_method((1, 1))
```
Suggestion of possible fixes:
* Make sure it is a typo.
* Create a valid custom MyBackendArray and initialize it. So it is easier to tell if it's a typo.
* Add type hinting so mypy can easier catch these errors.
### 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
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/7450/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,,13221727,issue
1376776178,I_kwDOAMm_X85SD-_y,7049,Backend entrypoints not public?,14371165,closed,0,,,0,2022-09-17T13:41:13Z,2022-10-26T16:01:06Z,2022-10-26T16:01:06Z,MEMBER,,,,"### What is your issue?
As I've understood it `ZarrBackendEntrypoint` is the engine used when loading zarr-files. But for some reason we show `ZarrStore` in `xr.backends`.
I believe the `ZarrStore` class is supposed to be just a implementation detail, right?
```python
# The available engines:
xr.backends.list_engines()
Out[23]:
{'netcdf4': ,
'h5netcdf': ,
'scipy': ,
'pseudonetcdf': ,
'pydap': ,
'store': ,
'zarr': }
# The public class is ZarrStore instead of ZarrBackendEntrypoint, how come?
dir(xr.backends)
Out[22]:
['AbstractDataStore',
'BackendArray',
'BackendEntrypoint',
'CachingFileManager',
'CfGribDataStore',
'DummyFileManager',
'FileManager',
'H5NetCDFStore',
'InMemoryDataStore',
'NetCDF4DataStore',
'NioDataStore',
'PseudoNetCDFDataStore',
'PydapDataStore',
'ScipyDataStore',
'ZarrStore',
'__all__',
'__builtins__',
'__cached__',
'__doc__',
'__file__',
'__loader__',
'__name__',
'__package__',
'__path__',
'__spec__',
'api',
'cfgrib_',
'common',
'file_manager',
'h5netcdf_',
'list_engines',
'locks',
'lru_cache',
'memory',
'netCDF4_',
'netcdf3',
'plugins',
'pseudonetcdf_',
'pydap_',
'pynio_',
'rasterio_',
'scipy_',
'store',
'zarr']
```","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/7049/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue
1410534774,I_kwDOAMm_X85UEw12,7170,Scatter plots overlap in facetgrid in 3d,14371165,open,0,,,0,2022-10-16T16:06:56Z,2022-10-16T16:08:55Z,,MEMBER,,,,"### What happened?
Any matplotlib gurus have any ideas how to nicely fit 3d plots in facetgrid?
```python
ds = xr.tutorial.scatter_example_dataset(seed=42)
fg = ds.plot.scatter(x=""A"", y=""B"", z=""z"", hue=""y"", markersize=""x"", row=""x"", col=""w"")
```

2d looks fine:
```python
fg = ds.plot.scatter(x=""A"", y=""B"", hue=""y"", markersize=""x"", row=""x"", col=""w"")
```

### What did you expect to happen?
No plots overlapping each other, even if rotating the plots.
### 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
xr.show_versions()
INSTALLED VERSIONS
------------------
commit: None
python: 3.10.6 | packaged by conda-forge | (main, Aug 22 2022, 20:30:19) [MSC v.1929 64 bit (AMD64)]
python-bits: 64
OS: Windows
OS-release: 10
machine: AMD64
processor: Intel64 Family 6 Model 58 Stepping 9, GenuineIntel
byteorder: little
LC_ALL: None
LANG: en
LOCALE: ('Swedish_Sweden', '1252')
libhdf5: 1.12.2
libnetcdf: 4.8.1
xarray: 2022.9.1.dev266+gbd01f9cc.d20221006
pandas: 1.5.0
numpy: 1.23.3
scipy: 1.9.1
netCDF4: 1.6.1
pydap: installed
h5netcdf: 1.0.2
h5py: 3.7.0
Nio: None
zarr: 2.13.2
cftime: 1.6.2
nc_time_axis: 1.4.1
PseudoNetCDF: 3.2.2
rasterio: 1.3.2
cfgrib: None
iris: 3.3.0
bottleneck: 1.3.5
dask: 2022.9.2
distributed: 2022.9.2
matplotlib: 3.6.0
cartopy: 0.21.0
seaborn: 0.12.0
numbagg: 0.2.1
fsspec: 2022.8.2
cupy: None
pint: 0.19.2
sparse: 0.13.0
flox: 0.5.10.dev21+g91b6e19
numpy_groupies: 0.9.19
setuptools: 65.4.1
pip: 22.2.2
conda: None
pytest: 7.1.3
IPython: 7.33.0
sphinx: 5.2.3
C:\Users\J.W\anaconda3\envs\xarray-tests\lib\site-packages\_distutils_hack\__init__.py:33: UserWarning: Setuptools is replacing distutils.
warnings.warn(""Setuptools is replacing distutils."")
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/7170/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,,13221727,issue
778083748,MDU6SXNzdWU3NzgwODM3NDg=,4761,Dataset.interp drops boolean variables,14371165,closed,0,,,0,2021-01-04T13:09:56Z,2021-05-13T15:28:15Z,2021-05-13T15:28:15Z,MEMBER,,,,"
**What happened**:
`Dataset.interp` silently drops boolean variables.
**What you expected to happen**:
If I'm interpolating a group of variables I expect to get all of them back in the correct shape with relevant values in them.
If the variables are boolean or object arrays I don't expect it to do linear interpolation because it doesn't make sense but stepwise interpolation like nearest or zero order interpolation should be fine to expect.
**Minimal Complete Verifiable Example**:
```python
import numpy as np
a = np.arange(0, 5)
b = np.core.defchararray.add(""long_variable_name"", a.astype(str))
coords = dict(time=da.array([0, 1]))
data_vars = dict()
for v in b:
data_vars[v] = xr.DataArray(
name=v,
data=np.array([0, 1]).astype(bool),
dims=[""time""],
coords=coords,
)
ds1 = xr.Dataset(data_vars)
# Print raw data:
print(ds1)
Out[3]:
Dimensions: (time: 2)
Coordinates:
* time (time) int32 0 1
Data variables:
long_variable_name0 (time) bool False True
long_variable_name1 (time) bool False True
long_variable_name2 (time) bool False True
long_variable_name3 (time) bool False True
long_variable_name4 (time) bool False True
# Interpolate:
ds1 = ds1.interp(
time=da.array([0, 0.5, 1, 2]),
assume_sorted=True,
method=""nearest"",
kwargs=dict(fill_value=""extrapolate""),
)
# Print interpolated data:
Dimensions: (time: 4)
Coordinates:
* time (time) float64 0.0 0.5 1.0 2.0
Data variables:
*empty*
```
**Anything else we need to know?**:
`ds.interp_like `use `ds.reindex` in these cases which seems like a good choice in `ds.interp` as well. But I think that both `ds.interp` and `ds.interp_like` should fill by default with nearest value instead of np.nan because we're still requesting interpolation.
**Environment**:
Output of xr.show_versions()
xr.show_versions()
INSTALLED VERSIONS
------------------
commit: None
python: 3.8.5 (default, Sep 3 2020, 21:29:08) [MSC v.1916 64 bit (AMD64)]
python-bits: 64
OS: Windows
libhdf5: 1.10.4
libnetcdf: None
xarray: 0.16.2
pandas: 1.1.5
numpy: 1.17.5
scipy: 1.4.1
netCDF4: None
pydap: None
h5netcdf: None
h5py: 2.10.0
Nio: None
zarr: None
cftime: None
nc_time_axis: None
PseudoNetCDF: None
rasterio: None
cfgrib: None
iris: None
bottleneck: 1.3.2
dask: 2020.12.0
distributed: 2020.12.0
matplotlib: 3.3.2
cartopy: None
seaborn: 0.11.1
numbagg: None
pint: None
setuptools: 51.0.0.post20201207
pip: 20.3.3
conda: 4.9.2
pytest: 6.2.1
IPython: 7.19.0
sphinx: 3.4.0
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/4761/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue
791725552,MDU6SXNzdWU3OTE3MjU1NTI=,4838,Simplify adding custom backends,14371165,closed,0,,,0,2021-01-22T06:02:53Z,2021-04-15T02:02:03Z,2021-04-15T02:02:03Z,MEMBER,,,,"
**Is your feature request related to a problem? Please describe.**
I've been working on opening custom hdf formats in xarray, reading up on the apiv2 it is currently only possible to declare a new external plugin in setup.py but that doesn't seem easy or intuitive to me.
**Describe the solution you'd like**
Why can't we simply be allowed to add functions to the engine parameter? Example:
```python
from custom_backend import engine
ds = xr.load_dataset(filename, engine=engine)
```
This seems like a small function change to me from my initial _quick_ look because there's mainly a bunch of string checks in the normal case until we get to the registered backend functions, if we send in a function instead in the engine-parameter we can just bypass those checks.
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/4838/reactions"", ""total_count"": 2, ""+1"": 2, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue