Skip to content

Published 1.1.127

Compare
Choose a tag to compare
@erictraut erictraut released this 31 Mar 20:07

Bug Fix: Fixed bug in type evaluator that resulted in suppressed errors and evaluations when the evaluation of a lambda expression resulted in some form of recursion (e.g. it references a symbol that depends on the return result of the lambda).

Enhancement: Added "reportTypedDictNotRequiredAccess" diagnostic rule and split out diagnostics that pertain specifically to unguarded accesses to non-required TypedDict keys.

Bug Fix: Changed type of __path__ variable in module from List[str] to Iterable[str].

Bug Fix: Fixed bug that resulted in a runtime crash within the type checker when a protocol class inherits from another protocol class that is not generic (like "Sized").

Enhancement: Added better heuristics to auto-complete insertion logic so it honors single-symbol-per-line and multi-symbol-per-line formats of "from x import a" statements.

Enhancement: Implemented a new check to validate that annotated types for "self" and "cls" parameters are supertypes of their containing classes.

Bug Fix (from pylance): Fixed bug that resulted in crashes when a broken symlink was encountered.

Bug Fix: Fixed recent regression that resulted in false positives when checking the type of a "self" parameter within a metaclass when the type annotation was of the form Type[T].

Enhancement: Added minimal support for "@no_type_check" decorator. It does not suppress errors, but it doesn't generate an error itself.

Enhancement: Added support for PEP 612 ParamSpecs to be used as type parameters for generic classes and generic type aliases. Previously, they were allowed only in the specialization of Callable.

Enhancement: Added out-of-bounds access check for index operations where the indexed type is a tuple object with known length and the index value is a negative integer literal value.

Bug Fix: Fixed bugs in the handling of PEP 487 __init_subclass__. The logic was using the __init_subclass__ defined in the class itself rather than its base classes.

Enhancement: Added special-case handling for generic functions that return a Callable with generic parameters. The change allows for callers to pass type variables to the function and then have the resulting Callable provide a TypeVar scope for those variables.

Bug Fix (from pylance): Fixed bugs relating to partial type stub packages.