astropy / astropy/astropy

TST: isspmatrix_csr is deprecated in scipy-dev

Open Beginner friendly
#20,164 0 comments 0 reactions 0 assignees View on GitHub
nddata numpy-dev
Dominant language
Python
Stars
5.3k
Forks
2.2k
Avg merge
1d 18h
Merged PRs (30d)
74

Description

Example log: https://github.com/astropy/astropy/actions/runs/30549199357/job/90893342732 (ignore the `_unwrap` stuff being handled separately in https://github.com/astropy/astropy/pull/20132 )

Affects `nddata` tests.

---

All sparse matrix classes (`*_matrix`) are being deprecated in favor of sparse arrays (`*_array`), which have a NumPy-compatible API, e.g. `*` is elementwise multiplication. See the `spmatrix` to `sparray` migration guide https://docs.scipy.org/doc/scipy/reference/sparse.migration_to_sparray.html

The `isspmatrix_csr` function will be removed no earlier than v2.2.

Contributor guide

Open the contributing guide

Research direction

Start by searching the nddata tests for uses of isspmatrix_csr and read the affected test cases around those references. Update the tests to follow SciPy's sparse matrix-to-array migration guidance, then run the nddata test subset and confirm the deprecation warning is no longer triggered.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
testing
Issue type
Refactor
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.