Drop Python 3.11 support#674
Merged
Merged
Conversation
ax.figure is typed Figure | SubFigure | None, so accessing .colorbar directly raised a union-attr error. Narrow to non-None before use.
The slice/Iterable overload overlaps with the int/Hashable overload because str and tuple are both Hashable and Iterable[Hashable]. The overlap is structurally unavoidable, so suppress it in place.
|
|
||
| @overload | ||
| def __getitem__(self, x: slice | Iterable[Hashable]) -> ComparerCollection: ... | ||
| def __getitem__(self, x: slice | Iterable[Hashable]) -> ComparerCollection: ... # type: ignore[overload-overlap] |
numpy's current type stubs use the 3.12+ `type` statement, which mypy rejects when targeting 3.11, breaking the typecheck on every matrix job. Bump requires-python and mypy's target to 3.12 and drop 3.11 from the CI matrices.
3.14 is exercised in CI and allowed by requires-python, but was missing from the classifiers.
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.
Bumps the minimum Python to 3.12 across
requires-python, the trove classifiers, mypy's target, and the CI matrices, and fixes the two mypy errors that 3.11 was masking.mikeio's
mainbranch now requires Python >=3.12 (SPEC 0), which made thetest-mikeio-maincanary job fail at dependency resolution: uv resolves for every supported Python version, and 3.11 is no longer satisfiable. Since mikeio is a core dependency, modelskill follows the same policy.This also fixes the typecheck CI, where numpy's current type stubs use the 3.12+
typestatement that mypy rejects when targeting 3.11.