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
638947370,MDU6SXNzdWU2Mzg5NDczNzA=,4156,writing sparse to netCDF,2448579,open,0,,,7,2020-06-15T15:33:23Z,2024-01-09T10:14:00Z,,MEMBER,,,,"I haven't looked at this too closely but it appears that this is a way to save MultiIndexed datasets to netCDF. So we may be able to do `sparse -> multiindex -> netCDF`
http://cfconventions.org/Data/cf-conventions/cf-conventions-1.8/cf-conventions.html#compression-by-gathering
cc @fujiisoup ","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/4156/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,,13221727,issue
1672288892,I_kwDOAMm_X85jrRp8,7764,Support opt_einsum in xr.dot,2448579,closed,0,,,7,2023-04-18T03:29:48Z,2023-10-28T03:31:06Z,2023-10-28T03:31:06Z,MEMBER,,,,"### Is your feature request related to a problem?
Shall we support [opt_einsum](https://dgasmith.github.io/opt_einsum/) as an optional backend for `xr.dot`?
`opt_einsum.contract` is a drop-in replacement for `np.einsum` so this monkey-patch works today
```
xr.core.duck_array_ops.einsum = opt_einsum.contract
```
### Describe the solution you'd like
Add a `backend` kwarg with options `""numpy""` and `""opt_einsum""`, with the default being `""numpy""`
### Describe alternatives you've considered
We could create a new package but it seems a bit silly.
### Additional context
_No response_","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/7764/reactions"", ""total_count"": 3, ""+1"": 3, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue
1916012703,I_kwDOAMm_X85yNAif,8239,Address repo-review suggestions,2448579,open,0,,,7,2023-09-27T17:18:40Z,2023-10-02T20:24:34Z,,MEMBER,,,,"### What is your issue?
Here's the output from the Scientific Python [Repo Review](https://repo-review.readthedocs.io/) tool.
There's an online version [here](https://learn.scientific-python.org/development/guides/repo-review/?repo=pydata%2Fxarray&branch=main).
On mac I run
```
pipx run 'sp-repo-review[cli]' --format html --show err gh:pydata/xarray@main | pbcopy
```
A lot of these seem fairly easy to fix. I'll note that there's a large number of `mypy` config suggestions.
General
- Detected build backend:
setuptools.build_meta
- Detected license(s): Apache Software License
PyProject
See https://github.com/pydata/xarray/issues/8239#issuecomment-1739363809
? | Name | Description |
❌ |
PP305 |
Specifies xfail_strict
xfail_strict should be set. You can manually specify if a check
should be strict when setting each xfail.
[tool.pytest.ini_options]
xfail_strict = true
|
❌ |
PP308 |
Specifies useful pytest summary
-ra should be in addopts = [...] (print summary of all fails/errors).
[tool.pytest.ini_options]
addops = ["-ra", "--strict-config", "--strict-markers"]
|
Pre-commit
? | Name | Description |
❌ |
PC110 |
Uses black
Use https://github.com/psf/black-pre-commit-mirror instead of https://github.com/psf/black in .pre-commit-config.yaml
|
❌ |
PC160 |
Uses codespell
Must have https://github.com/codespell-project/codespell repo in .pre-commit-config.yaml
|
❌ |
PC170 |
Uses PyGrep hooks (only needed if RST present)
Must have https://github.com/pre-commit/pygrep-hooks repo in .pre-commit-config.yaml
|
❌ |
PC180 |
Uses prettier
Must have https://github.com/pre-commit/mirrors-prettier repo in .pre-commit-config.yaml
|
❌ |
PC191 |
Ruff show fixes if fixes enabled
If --fix is present, --show-fixes must be too.
|
❌ |
PC901 |
Custom pre-commit CI message
Should have something like this in .pre-commit-config.yaml :
ci:
autoupdate_commit_msg: 'chore: update pre-commit hooks'
|
MyPy
? | Name | Description |
❌ |
MY101 |
MyPy strict mode
Must have strict in the mypy config. MyPy is best with strict or
nearly strict configuration. If you are happy with the strictness of
your settings already, ignore this check or set strict = false
explicitly.
[tool.mypy]
strict = true
|
❌ |
MY103 |
MyPy warn unreachable
Must have warn_unreachable = true to pass this check. There are
occasionally false positives (often due to platform or Python version
static checks), so it's okay to ignore this check. But try it first - it
can catch real bugs too.
[tool.mypy]
warn_unreachable = true
|
❌ |
MY104 |
MyPy enables ignore-without-code
Must have "ignore-without-code" in enable_error_code = [...] . This
will force all skips in your project to include the error code, which
makes them more readable, and avoids skipping something unintended.
[tool.mypy]
enable_error_code = ["ignore-without-code", "redundant-expr", "truthy-bool"]
|
❌ |
MY105 |
MyPy enables redundant-expr
Must have "redundant-expr" in enable_error_code = [...] . This helps
catch useless lines of code, like checking the same condition twice.
[tool.mypy]
enable_error_code = ["ignore-without-code", "redundant-expr", "truthy-bool"]
|
❌ |
MY106 |
MyPy enables truthy-bool
Must have "truthy-bool" in enable_error_code = [] . This catches
mistakes in using a value as truthy if it cannot be falsey.
[tool.mypy]
enable_error_code = ["ignore-without-code", "redundant-expr", "truthy-bool"]
|
Ruff
? | Name | Description |
❌ |
RF101 |
Bugbear must be selected
Must select the flake8-bugbear B checks. Recommended:
[tool.ruff]
select = [
"B", # flake8-bugbear
]
|
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/8239/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,,13221727,issue
1409811164,I_kwDOAMm_X85UCALc,7162,copy of custom index does not align with original,2448579,closed,0,,,7,2022-10-14T20:17:22Z,2023-03-24T20:37:13Z,2023-03-24T20:37:12Z,MEMBER,,,,"### What happened?
MY prototype CRSIndex is broken on the release version: https://github.com/dcherian/crsindex/blob/main/crsindex.ipynb under heading ""BROKEN: Successfully align with a copy of itself""
The cell's code is :
```
copy = newds.copy(deep=True)
xr.align(copy, newds)
```
which should always work.
@headtr1ck is https://github.com/pydata/xarray/pull/7140 to blame?
### Environment
INSTALLED VERSIONS
------------------
commit: None
python: 3.10.6 | packaged by conda-forge | (main, Aug 22 2022, 20:43:44) [Clang 13.0.1 ]
python-bits: 64
OS: Darwin
OS-release: 21.6.0
machine: x86_64
processor: i386
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8
LOCALE: ('en_US', 'UTF-8')
libhdf5: 1.12.2
libnetcdf: 4.8.1
xarray: 2022.10.0
pandas: 1.5.0
numpy: 1.23.3
scipy: 1.9.1
netCDF4: 1.6.0
pydap: None
h5netcdf: 1.0.2
h5py: 3.7.0
Nio: None
zarr: 2.13.3
cftime: 1.6.2
nc_time_axis: 1.4.1
PseudoNetCDF: 3.2.2
rasterio: 1.3.2
cfgrib: 0.9.10.2
iris: 3.3.1
bottleneck: 1.3.5
dask: 2022.9.2
distributed: 2022.9.2
matplotlib: 3.6.1
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.6.0
numpy_groupies: 0.9.19
setuptools: 65.5.0
pip: 22.2.2
conda: None
pytest: 7.1.3
IPython: 8.5.0
sphinx: None
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/7162/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue
570190199,MDU6SXNzdWU1NzAxOTAxOTk=,3796,RTD failing yet again,2448579,closed,0,,,7,2020-02-24T22:35:52Z,2020-03-24T22:23:00Z,2020-03-24T22:23:00Z,MEMBER,,,,"memory consumption errors as usual.
@keewis I remember you had an idea for using pip instead of conda?","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/3796/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,completed,13221727,issue