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/pull/2492#issuecomment-431868326,https://api.github.com/repos/pydata/xarray/issues/2492,431868326,MDEyOklzc3VlQ29tbWVudDQzMTg2ODMyNg==,1217238,2018-10-22T15:26:24Z,2018-10-22T15:26:24Z,MEMBER,thanks @alexamici ,"{""total_count"": 1, ""+1"": 1, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431559524,https://api.github.com/repos/pydata/xarray/issues/2492,431559524,MDEyOklzc3VlQ29tbWVudDQzMTU1OTUyNA==,226037,2018-10-20T08:11:03Z,2018-10-20T08:11:03Z,MEMBER,"@shoyer I consider https://github.com/pydata/xarray/pull/2492/commits/486a391915d3bf1af685ae9ef908c30d5e053851 in a mergiable state if you like it.
I updated the description of the PR to sync with the new aim.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431477498,https://api.github.com/repos/pydata/xarray/issues/2492,431477498,MDEyOklzc3VlQ29tbWVudDQzMTQ3NzQ5OA==,226037,2018-10-19T19:44:33Z,2018-10-19T19:45:48Z,MEMBER,"And we ""refuse to guess""!
I broke the forrest of `try / except` to different functions with no real change (hopefully!) except `_get_default_engine_grib`.
Now opening a GRIB file without explicit `engine` raises an exception, but the error message suggests to the user to use the installed backend or to install one if none is present.
@shoyer if this too complex? Alternatively I can always return the same, generic, error message.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431463477,https://api.github.com/repos/pydata/xarray/issues/2492,431463477,MDEyOklzc3VlQ29tbWVudDQzMTQ2MzQ3Nw==,1924696,2018-10-19T18:55:13Z,2018-10-19T18:55:13Z,NONE,"@shoyer, I also agree that requiring a backend to be explicitly selected for grib files would be a better solution from a user experience perspective, as opposed to silently replacing PyNIO with cfgrib (inconsistent variable names would be a major concern).
As @jhamman mentioned, we have been evaluating the long-term viability of PyNIO and are considering putting it into ""maintenance mode"". Unfortunately, the lead developer of PyNIO retired last year, and we don't have the budget to replace him at this time.
We intend to continue fixing bugs in PyNIO as necessary (versions 1.5.1, 1.5.2, and 1.5.3 have all been released in the last three months), and we will also continue supporting the [conda-forge/pynio-feedstock](https://github.com/conda-forge/pynio-feedstock) recipe. However, no new functionality (such as updating/adding grib tables) is part of our current long-term plan for PyNIO.
(cc'ing @marylhaley in case she has any additional input to offer)","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431428116,https://api.github.com/repos/pydata/xarray/issues/2492,431428116,MDEyOklzc3VlQ29tbWVudDQzMTQyODExNg==,2443309,2018-10-19T16:53:25Z,2018-10-19T16:53:25Z,MEMBER,"Totally agree with what @shoyer just wrote. I will add the pynio team is considering mothballing pynio in the relatively near future. So long term, we may not have to make a choice here but for now, I support asking the user to make an explicit decision.
cc @khallock ","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431425504,https://api.github.com/repos/pydata/xarray/issues/2492,431425504,MDEyOklzc3VlQ29tbWVudDQzMTQyNTUwNA==,1217238,2018-10-19T16:44:19Z,2018-10-19T16:44:32Z,MEMBER,"As someone who hasn't opened up a grib file for several years, I'm not in a good position to choose which backend to use by default. For now, I would be inclined to hold off on making a default choice (unless there is a clear consensus among other xarray devs/users) in favor of requiring users to be explicit. This is somewhat inline with the Zen of Python: ""In the face of ambiguity, refuse the temptation to guess.""
Probably the best user experience would be to raise an informative error suggesting the use of cfgrib or pynio when opening a grib but no engine is specified, e.g.,
```
>>> xarray.open_dataset('data.grib')
ValueError: cannot open GRIB files without explicitly setting engine='pynio'
or engine='cfgrib' in xarray.open_dataset()
```","{""total_count"": 3, ""+1"": 3, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431297953,https://api.github.com/repos/pydata/xarray/issues/2492,431297953,MDEyOklzc3VlQ29tbWVudDQzMTI5Nzk1Mw==,226037,2018-10-19T09:09:54Z,2018-10-19T09:38:30Z,MEMBER,"@shoyer you are right, the GRIB translation is not unique and with *cfgrib* we have no plan to keep compatibility with *PyNIO*. I also agree that this will be really poor user experience πin some circumstances (even if in general it will work just fine). **Do not merge yet!**
We may default to one of the two without fall-back if it is not present (you may guess that I have a bias on which one to choose π), or keep the current behaviour.
In any event we can improve the error message by suggesting to add the `engine=` corresponding to the installed backends.
I'll show you what I mean.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431166092,https://api.github.com/repos/pydata/xarray/issues/2492,431166092,MDEyOklzc3VlQ29tbWVudDQzMTE2NjA5Mg==,1217238,2018-10-18T21:15:10Z,2018-10-18T21:15:10Z,MEMBER,"Actually, thinking about this a little more, I'm not entirely sure it makes sense to fallback from using pynio to cfgrib. The problem is that these libraries may interpret GRIB files differently, e.g., with different variable names. It could make for a poor user experience for `open_dataset('mydata.grib')` to work differently when different dependencies are installed.
(please let me know if I'm mistaken here!)","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431082419,https://api.github.com/repos/pydata/xarray/issues/2492,431082419,MDEyOklzc3VlQ29tbWVudDQzMTA4MjQxOQ==,226037,2018-10-18T16:50:00Z,2018-10-18T16:50:20Z,MEMBER,"Mm... the private functions in `api.py` are not unit tested as they are not part of the API, I'll add a `test_backends_api.py` for the `_get_default_engine` tests and then others can use it to unit test the other `_` functions. ","{""total_count"": 1, ""+1"": 1, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-431053815,https://api.github.com/repos/pydata/xarray/issues/2492,431053815,MDEyOklzc3VlQ29tbWVudDQzMTA1MzgxNQ==,1217238,2018-10-18T15:28:06Z,2018-10-18T15:28:06Z,MEMBER,"> The whole engine detection strategy looks a bit fragile as the .gz extension is recognised outside of _get_default_engine and the nested ifs and try / except blocks make the code poorly readable. I can add a bit of a refactor in this area if you think it is appropriate.
Agreed! Yes, this would be welcome.
I'm happy with this change, but it would be good to ensure we have test coverage. It looks like we currently don't have any unit tests, but I'm pretty sure the other code is exercised by integration tests. If you're up for adding unit tests for `_get_default_engine` that would be awesome.","{""total_count"": 1, ""+1"": 1, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413
https://github.com/pydata/xarray/pull/2492#issuecomment-430995861,https://api.github.com/repos/pydata/xarray/issues/2492,430995861,MDEyOklzc3VlQ29tbWVudDQzMDk5NTg2MQ==,24736507,2018-10-18T12:50:15Z,2018-10-18T12:50:15Z,NONE,"Hello @alexamici! Thanks for submitting the PR.
- There are no PEP8 issues in the file [`xarray/backends/api.py`](https://github.com/alexamici/xarray/blob/ffcc02e2f3ce82f1c30a2399cff941ea3f72c88c/xarray/backends/api.py) !
- There are no PEP8 issues in the file [`xarray/core/utils.py`](https://github.com/alexamici/xarray/blob/ffcc02e2f3ce82f1c30a2399cff941ea3f72c88c/xarray/core/utils.py) !
","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,371514413