Skip to content

fix(docs): resolve NumPy NDArray alias references - #1324

Closed
viranovskaya wants to merge 2 commits into
scverse:mainfrom
viranovskaya:fix/docs-ndarray-links
Closed

viranovskaya wants to merge 2 commits into
scverse:mainfrom
viranovskaya:fix/docs-ndarray-links

Conversation

@viranovskaya

@viranovskaya viranovskaya commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Description

Strict documentation builds currently fail on the conditional_ratio, counts and zscore fields of NhoodEnrichmentResult: their generated Python class references to numpy.typing.NDArray do not match NumPy's py:data inventory entry. The same three warnings appear in an unrelated PR's Read the Docs build.

Normalize only this exact target's class role to its data role before the standard intersphinx resolver runs. This preserves the displayed type arguments and resolves to the public NumPy documentation without adding warning ignores, dependency pins or runtime changes.

How has this been tested?

  • Full strict HTML build with Python 3.12 and Sphinx 9.1.1: reproduced the three warnings on the unchanged base, then rebuilt with sphinx-build -M html docs <output> -W -E -a with zero warnings. Checked the actual links on all three field pages and confirmed that visible type text was unchanged.
  • Separate Python 3.14 / Sphinx 9.2.0 role-resolution probe using the production callback and real NumPy inventory: the three class-role links now resolve; existing data-role and numpy.ndarray class-role links remain intact. An unrelated missing target still fails the strict build. This was a focused Sphinx probe, not a full Squidpy documentation build on Python 3.14.
  • Full pytest run completed with 1550 passed, 2 skipped and 1 xfailed (4 reruns, no assertion failures). After writing JUnit results, the interpreter hung in thread shutdown and required SIGINT; this is not an intervention-free full-suite pass. The separate progress-thread cleanup in fix: clean up parallelize progress on errors #1323 is not included here.
  • All applicable pre-commit checks passed.

Closes

No linked issue. This is independent of the runtime changes in #1322 and #1323.

@codecov

codecov Bot commented Oct 27, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.86%. Comparing base (3a76b27) to head (249acc0).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1324   +/-   ##
=======================================
  Coverage   78.86%   78.86%           
=======================================
  Files          65       65           
  Lines        9611     9611           
  Branches     1591     1591           
=======================================
  Hits         7580     7580           
  Misses       1500     1500           
  Partials      531      531           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@selmanozleyen

Copy link
Copy Markdown
Member

thanks but I will fix this with an ignore then opening a public issue to sphinx! but thanks for the interest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants