Skip to content
This repository was archived by the owner on Sep 10, 2026. It is now read-only.

Fix tests - #130

Merged
brianhelba merged 1 commit into
masterfrom
fix-tests
Jan 17, 2026
Merged

brianhelba merged 1 commit into
masterfrom
fix-tests

Conversation

@brianhelba

Copy link
Copy Markdown
Contributor

No description provided.

Comment on lines -18 to -19
np._typing.NDArray[np.uint8]: A numpy uint8 3D array (image) to
render.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Docstrings are nice for explaining the semantics of parameters and return values, but I think we should avoid duplicating type information in them.

Of course, before formal Python typing via language syntax, it was more common to put type information in docstrings.

Comment on lines +9 to +10
if TYPE_CHECKING:
import numpy.typing as npt

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See https://numpy.org/doc/stable/reference/typing.html#api and other usage in the code.

For a rigorous library like numpy, there ought to be no need to import private symbols (it's a red flag that "there ought to be a better way"). I appreciate this doesn't hold for other lower-software-quality libraries.

@brianhelba
brianhelba merged commit af52a7d into master Jan 17, 2026
2 checks passed
@brianhelba
brianhelba deleted the fix-tests branch January 17, 2026 21:22
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant