id,node_id,number,state,locked,title,user,body,created_at,updated_at,closed_at,merged_at,merge_commit_sha,assignee,milestone,draft,head,base,author_association,auto_merge,repo,url,merged_by
78510209,MDExOlB1bGxSZXF1ZXN0Nzg1MTAyMDk=,917,closed,0,added to_dict function for xarray objects,4806877,"After the conversation #432 
",2016-07-22T17:14:03Z,2016-10-17T20:33:02Z,2016-08-11T21:54:25Z,2016-08-11T21:54:25Z,b708f71f05cccfc4c7063ea58c25c46cfe37dd8d,,,0,592f7bcfcb97871caa6ec982587a6c853a7b8198,9fe2aff89494f0f268dc98bcb549246837d0ae89,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/917,
89891374,MDExOlB1bGxSZXF1ZXN0ODk4OTEzNzQ=,1052,closed,0,catch numpy arrays in attrs before converting to dict,4806877,"Makes it easier to dump to json (after conversation on #917)
",2016-10-18T20:22:50Z,2016-10-25T18:19:50Z,2016-10-25T18:19:45Z,2016-10-25T18:19:45Z,293922eba4f5856e23c56a7f9c63482e1f47decb,,,0,f4ce8a8bfb3af90a8f7e5dedd2b50465a42e6b82,62a7f2c00caacb5b917ff320e28aca9cb4396649,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/1052,
148502414,MDExOlB1bGxSZXF1ZXN0MTQ4NTAyNDE0,1654,closed,0,[DOCS] PyNIO is now available on conda-forge,4806877,"Just a docs change. Updated instructions for installing PyNIO to use conda-forge.
",2017-10-24T20:19:28Z,2017-10-24T20:20:02Z,2017-10-24T20:19:59Z,2017-10-24T20:19:59Z,177b864333a61eb5c53b589c1a3cf48591d19b0d,,,0,ab4896ab911c88fa0b2a32dc88cb56dca625f156,423d3902ae432989a8a28bf9608621805d7095c5,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/1654,
209931263,MDExOlB1bGxSZXF1ZXN0MjA5OTMxMjYz,2375,closed,0,Make `dim` optional on unstack,4806877," - [x] Tests added (for all bug fixes or enhancements)
 - [x] Tests passed (for all non-documentation changes)
 - [x] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API (remove if this change should not be visible to users, e.g., if it is an internal clean-up, or if this is part of a larger project that will be documented later)


Not sure if this is a desirable change but I thought it could be easily discussed as a PR. Just for context I was looking at flattening spatial data for machine learning pipelines and then reshaping after the output had been acquired. 

I have a NxM array called `b` and am flattening it like:

```python
flat_input = b.stack(z=('y', 'x'))
```

Then I use that flat_input in my ML pipeline and get back an `np.array` (called `output`) which I want to unstack using all the metadata that went into stacking my original NxM array b.

```python
xr.full_like(flat_input, output).unstack(dim='z')
```

This PR just makes the `dim` argument optional in unstack so that we can use 

```python
xr.full_like(flat_input, output).unstack()
```

As a follow on PR I was thinking of making a function called `xr.unstack_like(other: xr.DataArray|xr.Dataset, data: array_like)` to encompass this functionality. A couple questions:

1) Would something like `xr.unstack_like` be desirable?
2) Should we be using `xr.full_like` in this way? The documentation in xarray and numpy only mentions scalars, but arrays work fine in both. If this is a supported behavior I could add docs, and if not perhaps a copy and overwrite is a better approach?

Here is a gist of the workflow using a tweaked datashader example and datashader example data https://gist.github.com/jsignell/79a6cf2da5c1458211d9dcf34d4417df",2018-08-21T19:29:06Z,2018-09-05T16:01:23Z,2018-09-05T15:19:07Z,2018-09-05T15:19:07Z,73f5b02a42a4003815d2bfc91e658195f5050be1,,,0,7ec32529652c9b19b18e747154a31b20d2c57b6e,69086b332c6c950587830b266df4e624c2106d89,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/2375,
211114053,MDExOlB1bGxSZXF1ZXN0MjExMTE0MDUz,2384,closed,0,Adding data kwarg to copy to create new objects with same structure  as original,4806877," - [x] Tests added (for all bug fixes or enhancements)
 - [x] Tests passed (for all non-documentation changes)
 - [x] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API (remove if this change should not be visible to users, e.g., if it is an internal clean-up, or if this is part of a larger project that will be documented later)

This is a PR for the follow on work set out in https://github.com/pydata/xarray/pull/2375#issuecomment-415227870",2018-08-27T13:42:28Z,2018-09-19T13:04:39Z,2018-09-19T01:19:08Z,2018-09-19T01:19:08Z,b679f4a9edb2437d11f28bf6516fc7aa8d673acb,,,0,5f6ce936fac62c295ffede2470d5b4f04bfb315c,4de8dbc3b1de461c0c9d3b002e55d60b46d2e6d2,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/2384,
239651957,MDExOlB1bGxSZXF1ZXN0MjM5NjUxOTU3,2618,closed,0,Adding mask to open_rasterio,4806877,"<!-- Feel free to remove check-list items aren't relevant to your change -->

 - [x] Discussed in #1736
 - [x] Tests added
 - [ ] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API

Not sure if this is the right approach @snowman2",2018-12-18T22:24:04Z,2021-06-24T13:44:33Z,2021-06-23T16:14:28Z,,c8a656c6e48b8bdbccc58fb8a001bf40e7c5d998,,,0,68bdc7f8a50cbfa3c12832fb82d2104fec8971ac,6d93a95d05bdbfc33fff24064f67d29dd891ab58,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/2618,
330694079,MDExOlB1bGxSZXF1ZXN0MzMwNjk0MDc5,3425,closed,0,Html repr,4806877,"<!-- Feel free to remove check-list items aren't relevant to your change -->
This PR supersedes #1820 - see that PR for original discussion. See [this gist](https://nbviewer.jupyter.org/gist/jsignell/2b7843a6e4852198bf963fbd299e8d46) to try out the new MultiIndex and options functionality. 
 
 - [x] Closes #1627, closes #1820 
 - [x] Tests added
 - [x] Passes `black . && mypy . && flake8`
 - [x] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API

TODO:

 - [x] Add support for Multi-indexes
 - [x] Probably good to have some opt-in or fail back system in case where we (or users) know that the rendering will not work
 - [x] Add some tests
",2019-10-21T21:08:54Z,2019-10-25T07:00:26Z,2019-10-24T16:48:47Z,2019-10-24T16:48:46Z,ba48fbcd6ee14e0bbd8887a970a1125fde6769f0,,,0,1d960933ab252e0f79f7e050e6c9261d55568057,652dd3ca77dd19bbd1ab21fe556340c1904ec382,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/3425,
332152088,MDExOlB1bGxSZXF1ZXN0MzMyMTUyMDg4,3443,closed,0,jupyterlab dark theme,4806877,"<!-- Feel free to remove check-list items aren't relevant to your change -->

 - [ ] Closes #xxxx
 - [ ] Tests added
 - [x] Passes `black . && mypy . && flake8`
 - [ ] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API

Follow on to #3425 to include support for jupyterlab dark theme. Note that this includes slight color changes. The most striking of which is that in jupyterlab light and regular notebook the even rows are white like the background. 

## Jlab dark
<img width=""766"" alt=""Screen Shot 2019-10-24 at 12 57 56 PM"" src=""https://user-images.githubusercontent.com/4806877/67508281-b70dbb80-f65e-11e9-83a0-37407d0052c1.png"">

## Jlab light
<img width=""770"" alt=""Screen Shot 2019-10-24 at 12 58 34 PM"" src=""https://user-images.githubusercontent.com/4806877/67508283-b9701580-f65e-11e9-855c-17d3d5e5d136.png"">

## notebook
<img width=""775"" alt=""Screen Shot 2019-10-24 at 1 04 13 PM"" src=""https://user-images.githubusercontent.com/4806877/67508341-d6a4e400-f65e-11e9-8396-f584ee193eda.png"">

",2019-10-24T17:08:27Z,2019-10-29T03:47:28Z,2019-10-29T03:47:28Z,2019-10-29T03:47:28Z,43d07b7b1d389a4bfc95c920149f4caa78653e81,,,0,60218fb5e7ec71ba4bc8398adf41e0ea8d4f61a6,ba48fbcd6ee14e0bbd8887a970a1125fde6769f0,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/3443,
332226754,MDExOlB1bGxSZXF1ZXN0MzMyMjI2NzU0,3444,closed,0,Escaping dtypes,4806877,"<!-- Feel free to remove check-list items aren't relevant to your change -->

 - [ ] Closes #xxxx
 - [x] Tests added
 - [x] Passes `black . && mypy . && flake8`
 - [ ] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API

Follow-on to https://github.com/pydata/xarray/pull/3425 to make html_repr work with dtypes like '<U5'",2019-10-24T20:24:33Z,2019-10-24T21:51:18Z,2019-10-24T21:50:20Z,2019-10-24T21:50:20Z,bb0a5a2b1c71f7c2622543406ccc82ddbb290ece,,,0,89fe8bbd42f5104d095d67c48feef6f8c4f558e9,ba48fbcd6ee14e0bbd8887a970a1125fde6769f0,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/3444,
381597390,MDExOlB1bGxSZXF1ZXN0MzgxNTk3Mzkw,3812,closed,0,Turn on html repr by default,4806877,"<!-- Feel free to remove check-list items aren't relevant to your change -->

 - [x] Closes #3806 
 - [x] Passes `isort -rc . && black . && mypy . && flake8`
 - [x] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API
",2020-02-28T21:12:43Z,2020-03-26T02:19:22Z,2020-03-02T23:01:44Z,2020-03-02T23:01:44Z,b155853ff6e17172b1b6b16c0da31522718e9409,,,0,a225878a0912968c022bbf4887f1bb82e9dfc811,8512b7bf498c0c300f146447c0b05545842e9404,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/3812,
993569436,PR_kwDOAMm_X847OKqc,6774,closed,0,Make the `sel` error more descriptive when `method` is unset,4806877,"- [x] Tests added

This came up in the tutorial and I was wondering if the error could be made a little clearer. Not sure if the error message should hint that a user might want to use ``method``.

```python
import numpy as np
import pandas as pd
import xarray as xr

arr = xr.DataArray(
    data=np.arange(48).reshape(4, 2, 6),
    dims=(""u"", ""v"", ""time""),
    coords={
        ""u"": [-3.2, 2.1, 5.3, 6.5],
        ""v"": [-1, 2.6],
        ""time"": pd.date_range(""2009-01-05"", periods=6, freq=""M""),
    },
)
arr.sel(u=5, time=""2009-04-28"")  # I removed `method=""nearest""`
```

Before this PR:

```python-traceback
...
KeyError: 5.0
```

After this PR:

```python-traceback
...
KeyError: ""not all values found in index 'u'. Did you mean to set `method=`?""
```
",2022-07-11T21:17:07Z,2022-07-13T14:49:24Z,2022-07-12T20:33:00Z,2022-07-12T20:33:00Z,4aae7fd0c39d4462d745dffc6c1eb880a5efa973,,,0,ecc3683ac13469301b6bccb4b7eb580b9fc464d7,7cc6cc991e586a6158bb656b8001234ccda25407,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/6774,
998210728,PR_kwDOAMm_X847f3yo,6792,closed,0,Raise an error if you pass an invalid key in `chunks`,4806877,"- [x] Tests added

This was a minor issue that came up at the Dask BOF. Currently if the key of chunks dict isn't included in the dims then it gets silently ignored. This PR makes xarray raise an error instead. 

I'm not sure if this is the right place to put this change. So just let me know if it should go somewhere else.

I changed an existing test. I am _pretty_ sure it was not intentionally using a key that isn't in the dims. ",2022-07-15T21:23:20Z,2022-08-02T15:57:50Z,2022-07-22T16:52:32Z,,640ceb9fd05550e9fc8d75e1f2e28559f448f8b9,,,0,6300884e581848748846983475bf00ad930bb4ef,5678b758bff24db28b53217c70da00c2fc0340a3,CONTRIBUTOR,,13221727,https://github.com/pydata/xarray/pull/6792,