Should we deprecate the compat and encoding constructor arguments?
See original GitHub issueIn https://github.com/pydata/xarray/pull/1170#discussion_r94078121, @shoyer writes:
…I would consider deprecating the encoding argument to DataArray instead. It would also make sense to get rid of the compat argument to Dataset.
These extra arguments are not part of the fundamental xarray data model and thus are a little distracting, especially to new users.
@pydata/xarray and others, what do we think about deprecating the compat
argument to the Dataset
constructor and the encoding
arguement to the DataArray
(and Dataset
via #1170).
Issue Analytics
- State:
- Created 7 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
How and When to Deprecate APIs
Deprecation is a reasonable choice in all these cases because it preserves "backward compatibility" while encouraging developers to change to the new API....
Read more >Solidity v0.5.0 Breaking Changes
Calling a constructor with arguments but with wrong argument count is now disallowed. If you only want to specify an inheritance relation without...
Read more >The @Deprecated Annotation in Java
The @Deprecated annotation tells the compiler that a method, class, or field is deprecated and that it should generate a warning if someone ......
Read more >ABI-Encoded Constructor Arguments
If Constructor Arguments are required by the contract, you will add them to the Constructor Arguments field in ABI hex encoded form. Constructor...
Read more >Deprecated and obsolete features - JavaScript - MDN Web Docs
This page lists features of JavaScript that are deprecated (that is, ... you should use the arguments object inside function closures.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I don’t have an opinion on
compat
(seems somehow unrelated to netCDF and https://github.com/pydata/xarray/issues/1170?), but I am +1 onencode
. I always useencode
when writing a dataset to disk, not at construction.We still have
compat
as an argument toDataset.__ini__
.I think we should probably deprecate it. I’ve never used it, and if you really want that high a level of control you can easily substitute using merge() instead.