github microsoft/pyright 1.1.62
Published 1.1.62

latest releases: 1.1.389, 1.1.388, 1.1.387...
4 years ago

Bug Fix: Fixed bug in the handling of unrecognized escape sequences within string literals.

Bug Fix: Fixed bug related to a subtle interaction between bidirectional type inference of list expressions that contain literal values and TypeVar matching. The previous logic was incorrectly matching T in List[T] and the list contained a literal type. It should have stripped the literal if possible.

Enhancement: Added diagnostic message for TypeVar with a single constraint type for consistency with mypy.

Enhancement: Added support for member access completion suggestions when the LHS is a function or a None type.

Behavior Change: Behavior change for type stub generator: don't emit __all__ assignments or assignments to self.xxx in function bodies. These violate PEP 484 guidelines for type stubs.

Enhancement: Added diagnostic check to reportInvalidStubStatement that flags parameter default value expressions that are not "..." in stub files.

Bug Fix: Fixed bug that caused annotated types of vargs and kwargs parameters not to be printed in hover text.

Enhancement: Implemented support for older-style function annotation type comments. I previously resisted adding this additional complexity, but we're seeing many libraries that still contain these annotations for backward compatibility with Python 2.

Bug Fix: Fixed bug that caused a crash in the type analyzer when a protocol class referred to itself.

Enhancement: Added support for "useLibraryCodeForTypes" option in config file. It overrides the client setting of the same name or the "--lib" command-line option.

Bug Fix: Fixed several bugs in logging for config errors.

Enhancement: Added logic to type checker to validate that the "self" or "cls" parameter with a specified type annotation is assignable when binding the method to an object or class.

Enhancement: Improved type assignment diagnostic message. Added "(property)" designator to the end of a property type to differentiate it from a normal attribute.

Enhancement: Added code to validate that method overloads are all abstract or not.

Enhancement: Updated typeshed stubs to the latest.

Don't miss a new pyright release

NewReleases is sending notifications on new releases.