Style: fix unused import and import ordering in multispectral.py#3432
Merged
Conversation
Remove unused not_implemented_func import (flake8 F401) and reorder project imports so isort passes (dataset_support before utils). No behavioural change. Also record the style-sweep state for this module.
brendancol
commented
Jun 20, 2026
brendancol
left a comment
Contributor
Author
There was a problem hiding this comment.
PR Review: Style fix for multispectral.py
Pure import-block cleanup. Two edits plus a sweep-state CSV row.
Blockers
None.
Suggestions
None.
Nits
None.
What looks good
- Dropping
not_implemented_funcis safe. It had no use in the module and there is no__all__re-export, so nothing external resolves the name throughmultispectral. - The isort reorder matches exactly what
isort --check-only --diffproduces. Bothflake8andisortare clean afterward. - The full
test_multispectral.pysuite (154 tests) still passes, which confirms the dropped import was genuinely dead. - No runtime code changed, so no numpy/cupy/dask parity check is needed.
Checklist
- N/A Algorithm matches reference (no algorithm change)
- N/A Backend parity (no runtime change)
- N/A NaN handling (no runtime change)
- OK Existing tests pass (154/154)
- N/A Dask chunk boundaries (no runtime change)
- OK No premature materialization (import-only diff)
- N/A Benchmark (style-only)
- N/A README matrix (no API change)
- OK Module still imports cleanly
…ispectral-2026-06-20 # Conflicts: # .claude/sweep-style-state.csv
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #3428
Style cleanup for
xrspatial/multispectral.py, surfaced by the style sweep using the project's ownsetup.cfgflake8 and isort config.Changes
not_implemented_funcimport fromxrspatial.utils(flake8 F401, Cat 3). Confirmed unused with no__all__, so it was not a re-export.dataset_supportprecedesutils(isort, Cat 4).Categories addressed: Cat 3 (F401), Cat 4 (isort). Cat 1/2/5 came back clean. No behavioural change is intended.
Backend coverage
Static import-block edits only. They apply uniformly across numpy / cupy / dask+numpy / dask+cupy, so no per-backend verification is needed.
Test plan
flake8 xrspatial/multispectral.pycleanisort --check-only --diff xrspatial/multispectral.pycleanpytest xrspatial/tests/test_multispectral.py(154 passed)not_implemented_funcis correctly no longer exposed as a module attribute