Bump mypy from 1.13.0 to 1.14.0
Bumps mypy from 1.13.0 to 1.14.0.
Changelog
Sourced from mypy's changelog.
Mypy Release Notes
Next release
...
Mypy 1.14
We’ve just uploaded mypy 1.14 to the Python Package Index (PyPI). Mypy is a static type checker for Python. This release includes new features and bug fixes. You can install it as follows:
python3 -m pip install -U mypy
You can read the full documentation for this release on Read the Docs.
Change to Enum Membership Semantics
As per the updated typing specification for enums, enum members must be left unannotated.
class Pet(Enum): CAT = 1 # Member attribute DOG = 2 # Member attribute # New error: Enum members must be left unannotated WOLF: int = 3 species: str # Considered a non-member attribute
In particular, the specification change can result in issues in type stubs (
.pyi
files), since historically it was common to leave the value absent:# In a type stub (.pyi file) class Pet(Enum): # Change in semantics: previously considered members, # now non-member attributes CAT: int DOG: int # Mypy will now issue a warning if it detects this # situation in type stubs: # > Detected enum "Pet" in a type stub with zero # > members. There is a chance this is due to a recent # > change in the semantics of enum membership. If so, # > use `member = value` to mark an enum member, </tr></table>
... (truncated)
Commits
-
6f37859
Remove +dev from version for release 1.14 -
5a6a754
Minor updates to 1.14 changelog (#18310) -
9772d48
Update changelog for release 1.14 (#18301) -
92473c8
Warn about --follow-untyped-imports (#18249) -
e6ce8be
PEP 702 (@deprecated
): descriptors (#18090) -
5082a22
[mypyc] Document optimized bytes ops and additional str ops (#18242) -
ee19ea7
[mypyc] Add primitives and specialization for ord() (#18240) -
cc45bec
[mypyc] Make exception type check in assertRaises test helper precise (#18241) -
f51090d
Make "deprecated" Note a standard Error, disabled by default (#18192) -
242873a
Implement flag to allow typechecking of untyped modules (#17712) - Additional commits viewable in compare view