Update testing routine with toxuv and ty - #86
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the project’s development/testing toolchain (tox + uv and adding the ty type checker) and applies a few small typing/import cleanups in the Python source to support stricter type-checking.
Changes:
- Switch tox configuration to
tox-uvand add a newtypetytox env to runty check. - Update CI to run the new
typetyenvironment and useuvin the test workflow. - Clean up typing/imports in plotting code and adjust internal typing annotations.
Reviewed changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/spei/utils.py | Removes an incorrect inline type comment while grouping data by year. |
| src/spei/si.py | Updates _dist_dict typing to use Timestamp keys. |
| src/spei/plot.py | Refactors matplotlib imports/types to be more explicit for type checking. |
| src/spei/knmi.py | Ensures numeric dtype when computing constrained cumulative sums. |
| pyproject.toml | Adds ty to typing extras; migrates tox to tox-uv; adds typety env. |
| README.md | Adds a ty type-checker badge and adjusts the mypy badge. |
| .github/workflows/tests.yml | Runs CI using uv + tox and adds a typety matrix entry. |
| .github/workflows/python-publish.yml | Updates action versions (but currently introduces a workflow YAML issue). |
| .github/workflows/draft-pdf.yml | Updates action versions for paper draft workflow. |
| .github/workflows/documentation.yml | Updates action versions for docs workflow. |
| .github/workflows/auto-author-assign.yml | Bumps the auto-author-assign action major version. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
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.
No description provided.