fix: point table validation to public sanitizer#1
Draft
stanbot8 wants to merge 1 commit into
Draft
Conversation
stanbot8
force-pushed
the
fix/1154-sanitize-table-path
branch
from
July 24, 2026 13:16
35c771b to
63a5780
Compare
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.
Preview. Text in square brackets becomes links in the submission.
Summary
The table-name validation error in issue [issue 1154] points to
spatialdata.utils.sanitize_table(adata). This path does not exist. The error now points tospatialdata.sanitize_table(adata). Closes issue 1154.Design
Use the top-level function that
spatialdataexports. Keep validation and sanitization behavior unchanged.The implementation changes [
src/spatialdata/_core/validation.py].Limitations
This change does not add a compatibility alias for the invalid
spatialdata.utilspath.Tests
The regression test fails on
mainand passes on this branch. The full suite passes with 1,365 tests, 7 skips, and 1 expected failure. The installed wheel passes the reported sanitize-and-validate workflow.The tests are in [
tests/models/test_models.py].All 7 [CPU matrix jobs] passed.
Commands
uv run pytest tests/models/test_models.py::TestModels::test_table_model_invalid_name_suggests_public_sanitizer -q