pyright

Static Type Checker for Python

OTHER License

Downloads
2.3M
Stars
13.2K
Committers
119

Bot releases are hidden (Show)

pyright - Published 1.1.180

Published by erictraut almost 3 years ago

Bug Fix: Fixed bug that resulted in a false positive error when a generic class used a specialized version of itself parameterized with one of its own type parameters.

Bug Fix: Fixed recent regression where imported symbols that were ultimately resolved with a native library (e.g. a ".pyd" or ".so" file) were incorrectly resolved as a module rather than an Unknown type.

Bug Fix: Fixed a type evaluation regression that caused type arguments to be incorrectly determined when calling a constructor and passing a callable that is generic.

Enhancement: Added broader support for context managers in with statements which swallow exceptions. Thanks to Rik de Graaff for this contribution.

Bug Fix: Added missing error condition for walrus operator used within a type annotation expression.

Bug Fix: Fixed bug in pattern matching type evaluation where bytearray was matched against a sequence pattern even though PEP 634 explicitly excludes this case.

Enhancement: Added support for sequence pattern match type narrowing when the subject type is a simple "object".

Enhancement: Added support for type narrowing of enums when using pattern matching.

Enhancement: Added error reporting for usage of type aliases within class pattern matching statements that generate runtime exceptions.

Behavior Change: Changed the printed type of a ParamSpec signature to avoid the use of synthesized parameter names "__p0", etc. Instead, the parameter names are omitted in the signature consistent with the emerging standard for the improved callable syntax.

Enhancement: Added support for explicit specialization of generic classes that include a ParamSpec. This is defined in PEP 612 but was previously missing.

Bug Fix: Fixed bug in check for generator return type. A diagnostic was meant to be generated if the declared return type was incorrect for a generator.

pyright - Published 1.1.179

Published by erictraut about 3 years ago

Enhancement: Added support for an unpacked tuple assignment within an instance method when the source of the assignment is the self parameter.

Bug Fix: Fixed false positive error in protocol variance check (in the reportInvalidTypeVarUse diagnostic rule) when a protocol class used a ParamSpec.

Bug Fix: Fixed bug that caused false positive errors when generic callback protocol class used a ParamSpec and a __call__ method with only two parameters consisting of P.args and P.kwargs.

Bug Fix: Fixed bug that resulted in a false positive error when using a generic callback protocol with a ParamSpec where the __call__ method included a positional-only marker prior to the P.args and P.kwargs parameters.

Bug Fix: Fixed a bug that results in false positive error when assigning a source union type to a destination union type.

Bug Fix: Fixed an internal crash that was caused by infinite recursion.

Bug Fix: Fixed bug in completion provider that resulted in inappropriate suggestions when typing arguments within a class declaration.

Bug Fix: Changed type logic for sequence pattern matching to produce list rather than tuple for star subpatterns. This matches the runtime behavior in Python 3.10.

Enhancement: Added support for name expressions in with statements where the name refers to a variable or parameter with a declared type that corresponds to a context manager class that swallows exceptions.

Bug Fix: Fixed bug that resulted in a false positive error when a generic class used a specialized version of itself parameterized with one of its own type parameters.

pyright - Published 1.1.178

Published by erictraut about 3 years ago

Bug Fix: Fixed false positive error that occurred when importing a symbol in a from x import y statement that referred to a chain of imports and was eventually resolved to a native library (e.g. ".pyd" or ".so" file).

Bug Fix: Added missing check for type compatibility between callables where the destination type includes a default argument for a parameter but the source type does not.

Bug Fix: Fixed bug that caused incorrect evaluation of inferred return type based on inferred type of unannotated "self" or "cls" parameter.

Enhancement: Added support for "narrowing" of TypedDict instances on assignment when the TypedDict defines entries that are not required but are supplied.

Behavior Change: Changed the interpretation of a property declared within a protocol class. It was previously interpreted only as a property (i.e. classes compatible with the protocol must implement a property of the same name). Compatible classes are now able to declare an attribute whose type is compatible with the property getter. Access to the property from the protocol class as a class variable is no longer allowed.

Enhancement: Improved error message for improper use of a module as a type argument.

Bug Fix: Fixed a bug in import resolution logic that resulted in incorrect resolution of a symbol in the presence of wildcard imports that allowed for multiple resolution paths, some of them cyclical. Pyright previously gave up when it detected a cycle rather than using a different (non-cyclical) resolution path.

Bug Fix: Improved parser's detection of "match" as a soft keyword versus some other usage of a symbol named "match".

Bug Fix: Fixed bug that resulted in a false negative when a TypedDict value was assigned to a protocol that included attributes that matched the TypedDict keys.

Bug Fix: Fixed bug that resulted in false positive when a function is used in an == or != binary expression.

Bug Fix (from pylance): Fixed bug in import completions for parent directory resolution.

pyright - Published 1.1.177

Published by erictraut about 3 years ago

Bug Fix: Fixed bug in stub generation logic. It wasn't properly handling module paths with more than a single ".", such as "google.cloud.storage".

Bug Fix: Fixed false positive error in certain cases where type variable was bound to a union.

Enhancement: Implemented check for an attempt to subclass an Enum class that defines one or more enumerated values. This condition generates a runtime exception.

Enhancement: Type aliases in the printed form of a union type are retained when aliased types are combined in a union.

Bug Fix: Fixed bug in completion provider's handling of key completions for TypedDicts.

Bug Fix: Fixed false positive type evaluation error when constrained TypeVar is assigned to a union that contains a compatible constrained TypeVar.

Bug Fix: Added code to work around the circular definition found in the typeshed stub that defines the os.scandir function.

pyright - Published 1.1.176

Published by erictraut about 3 years ago

Enhancement: Exempted check for unsafe access to TypedDict key if it's within a context manager. It was previously exempted if included in a try block, but some prefer to use a context manager to catch exceptions.

Behavior Change: Bumped pyright's default Python version from 3.9 to 3.10.

Enhancement: Added support for "bare" ClassVar annotations.

Enhancement: Updated to the latest version of typeshed stubs.

Enhancement: Added new "--warnings" command-line option that generates an exit code of 1 if one or more warnings are emitted. By default, only errors generate an exit code of 1.

Bug Fix: Fixed bug that resulted in a "unknown member of module" error if the member referred to a submodule that was imported privately from another module but that submodule was also explicitly imported. For example, if a module imports both a and a.b and then uses the symbol a.b.c.

Enhancement: Added new diagnostic check "reportMissingParameterType" that checks for function and method input parameters that are missing a type annotation.

Enhancement: Added support for new type guard pattern: x[I] is None and x[I] is not None where x is a tuple or union of tuples with known lengths and entry types and I is an integer.

Enhancement: Enhanced the stub generation logic to emit __all__ = ... and __all__ += ... statements when they appear in the module scope and are not within a conditional (if/else) block.

pyright - Published 1.1.175

Published by erictraut about 3 years ago

This is a "hot fix" release that addresses two regressions introduced in 1.1.174.

Bug Fix: Reverted a change that broke the use of generic dataclass types.

Bug Fix: Reverted a change that resulted in a false positive error when subclassing an Enum base class that defined no enumerated values.

pyright - Published 1.1.174

Published by erictraut about 3 years ago

Behavior Change: Modified import resolution logic to handle namespace stub packages. This case isn't explicitly covered by PEP 561, but there is a proposal to amend the PEP to clarify how to handle this case.

Bug Fix: Fixed bug that resulted in a false negative when dealing with types that are conditioned on constrained or bound TypeVars.

Bug Fix: Fixed bug that affected a missing type argument for a ParamSpec type parameter. It should be an Unknown type.

Bug Fix: Fixed bug that resulted in an Unknown type appearing in a type evaluation for an unannotated variable that is modified in a loop.

Enhancement: Added error reporting for an attempt to subclass an Enum class and a duplicate definition of enum members.

Enhancement: Improved error reporting for index expressions used for non-generic classes.

Enhancement: Fixed performance issue in stub generation code that caused stub generation to take longer than needed.

Enhancement: Added performance improvement that skips return type inference for functions whose parameters are not annotated and have a "code flow complexity" beyond a certain threshold.

Bug Fix: Fixed bug the resulted in a false positive when an overloaded function is passed as an argument to a function that accepts a callable parameter using generics.

Bug Fix: Fixed a false positive error when a class with an overloaded constructor is passed as an argument to a callable parameter.

Bug Fix: Fixed bug in type var matching logic that resulted in a false positive when using a generic class that conforms to a generic protocol and uses that protocol within its own method signatures.

pyright - Published 1.1.173

Published by erictraut about 3 years ago

Bug Fix: Fixed a false positive error with the new union syntax when the LHS expression is an Any or Unknown type.

Enhancement: Updated typeshed stubs to the latest.

Bug Fix: Fixed bug in ParamSpec specialization code that can occur when using a generic type alias with a ParamSpec.

Bug Fix: Fixed false positive error when assigning a callable to a callback protocol that includes a ParamSpec.

Bug Fix: Fixed bug that resulted in unbound variable condition not being reported if it was in a loop and was assigned conditionally.

Bug Fix: Fixed bug relating to the use of an Any type argument corresponding to a ParamSpec type parameter.

Bug Fix: Fixed a false positive error when using a generic descriptor class that is parameterized by the self or cls parameter of the class that allocates the descriptor.

Enhancement: Added check for inappropriate use of a field annotated with InitVar.

Bug Fix: Fixed bug that resulted in a false positive error when a protocol class used generic type parameters scoped to a method.

pyright - Published 1.1.172

Published by erictraut about 3 years ago

Enhancement: Added completion suggestion support for TypedDict keys and values. Thanks to Robert Cragie for this contribution!

Behavior Change: Changed behavior of reportInvalidTypeVarUse diagnostic check to flag bound type variables used as type arguments within return type annotations.

Enhancement: Implemented code that applies type narrowing to local variables and parameters when they are captured by an inner-scoped lambda or function and the variable or parameter is not reassigned after the lambda or function along any code flow paths.

Enhancement: Updated typeshed stubs to the latest.

Bug Fix: Fixed a bug in ParamSpec handling that resulted in false positives when a callable type containing a ParamSpec was assigned to another callable type containing a ParamSpec.

Enhancement (from pylance): Improved handling of type checking when files are opened in "single file" mode, rather than opening a project root directory.

Enhancement (from pylance): Implemented heuristic for detecting import roots within a project. Previously, these all needed to be specified through "extraPaths" settings, but now pyright is smarter about locating these directories automatically.

Bug Fix: Fixed false positive error when a generic class with a ParamSpec type parameter implements a descriptor protocol.

pyright - Published 1.1.171

Published by erictraut about 3 years ago

Bug Fix: Fixed bug in TypeVarTuple support that prevented the use of an unpacked TypeVarTuple within a type argument list for types other than Tuple or Union.

Bug Fix: Fixed bug in synthesized __new__ method for NamedTuple class that caused the constructor of subclasses of the NamedTuple to construct the base class.

Bug Fix: Fixed bug where a class whose constructor is unannotated was allowed to have explicit generic type arguments.

Behavior Change: Changed type evaluation behavior for protected instance variables (those that begin with a single underscore) and are assigned a literal value. Previously, the literal type was retained if the reportPrivateUsage was enabled. This caused various problems. It was a bad idea because type evaluations should not differ based on diagnostic reporting switches.

Enhancement: Added logic to report a diagnostic if an instance variable is assigned only via an augmented assignment expression.

Bug Fix (from pylance): Fixed bug in parser that resulted in incorrect text range for relative module names in import statements.

Bug Fix: Improved inference of generator statements that involve await statements to conform to the runtime behavior of the CPython intepreter.

Bug Fix: Fixed bug that caused inconsistent handling of dataclasses that use the @dataclass decorator and derive from abstract base classes.

Bug Fix: Fixed bug that caused yield expression to be evaluated as "unknown" in some cases when it was contained within a loop.

Bug Fix: Fixed bug that resulted in incorrect type evaluation for expressions within an await statement under some circumstances.

Behavior Change: Changed code that converts types to textual representation to prepend a tilde ("~") character for the inferred type of a "self" or "cls" parameter.

Enhancement: Updated typeshed stubs to the latest.

pyright - Published 1.1.170

Published by erictraut about 3 years ago

Bug Fix (from Pylance): Handle unrooted execution environments (e.g., open file mode), preventing various crashes and oddities.

Bug Fix (from Pylance): Generate default values in method overload signatures. Previously, we didn't include them, which generated the wrong signature.

Bug Fix (from Pylance): Use attribute docstrings for type aliases in completion and hover.

Bug Fix (from Pylance): Modify parser to change the range of parenthesized expressions to their contents. This improves the ranges returned in hovers, document highlight, etc.

Bug Fix: Improved member access logic to more faithfully match the Python interpreter's behavior when the member is assigned through a class, that member is a class itself, and that class has a metaclass that implements a descriptor protocol. It appears that the interpreter does not call through to the metaclass's __set__ method in this case, even though it does call its __get__ method when the member is accessed in the same circumstance.

Enhancement: Extended reportCallInDefaultInitializer diagnostic check to disallow list, set or dict expressions in default argument expression.

Bug Fix: Improved isinstance and issubclass narrowing to handle open-ended tuples passed as the second argument.

Bug Fix: Fixed false positive error when namedtuple constructor is called with a list of field names that includes dynamic (non-literal) expressions.

Bug Fix: Fixed false positive error where an exception class (as opposed to an exception object) is used in a "from" clause in a "raise" statement.

Enhancement: Added support for ParamSpec matching when used within a callback protocol. PEP 612 is unclear on whether this should be supported, by pyre (the reference implementation for the PEP) does support it.

Bug Fix: Fixed false negative error in parser where it did not correctly detect a syntax error when a walrus operator was used in a ternary operator condition expression.

Bug Fix: Fixed bug that resulted in false negative when bidirectional type inference involved an "expected type" of Any and the type being evaluated was a call expression that returned a generic object as a return value.

Bug Fix: Fixed infinite recursion bug in hover provider when a symbol referred to both a locally-defined class and an imported symbol.

Bug Fix: Fixed bug that resulted in false positive when using unpack operator with self when self refers to a named tuple or a tuple with known length.

Behavior Change: Allow symbols that are not explicitly re-exported from a stub to be imported into another stub. This change is required to support recent updates to typeshed.

Enhancement: Updated typeshed stubs to the latest.

pyright - Published 1.1.169

Published by erictraut about 3 years ago

Bug Fix: Improved type narrowing logic for a is b pattern where a is self (or a bound TypeVar) and b is an enum literal.

Bug Fix: Updated reportIncompatibleMethodOverride diagnostic check to special-case dict key names that overlap with method names in the _TypedDict class.

Bug Fix: Improved handling of attribute accesses for classes that inherit from Any or an unknown class.

Enhancement: Added optimization that reduces the time it takes to perform code flow analysis in the presence of if/elf/else statements, try statements, with statements, and ternary expressions.

Bug Fix: Fixed bug that caused false positive when a bound TypeVar is bound to an instantiable class (e.g. Type[X]).

pyright - Published 1.1.168

Published by erictraut about 3 years ago

Bug Fix: Fixed inconsistency in the constraint solver with respect to literal types. They were being retained for most classes but not for tuples.

Bug Fix: Fixed bug in parser that resulted in a false negative when a for keyword (in either a for statement or a list comprehension) was followed immediately by in keyword.

Behavior Change: Enforce PEP 484 rules for symbols that are imported by a stub file but are not meant to be re-exported. These symbols are no longer resolved when accessed outside of the module, nor are they included in completion suggestions or other language service providers.

Behavior Change: Modified logic for private symbols (whose names begin with an underscore) exported from a stub file or a py.typed source file; if the symbol is explicitly included in __all__ it is not considered private.

Enhancement: Added reportPrivateImportUsage diagnostic rule, which reports usage of a symbol from a py.typed library that is not intended to be re-exported by the library's author. The rule is on by default in basic type checking mode but can be disabled. Completion provider no longer offers these symbols as completion suggestions.

Bug Fix: Fixed bug that resulted in incorrect type evaluation when co-dependent variables were assigned in a loop using tuple assignments (e.g. a, b = b, a + 1).

Bug Fix: Improved isinstance and issubclass support to handle the case where the type of the second argument is a union where the subtypes includes both tuples of class types and non-tuples.

Enhancement: Updated typeshed to latest version

pyright - Published 1.1.167

Published by erictraut about 3 years ago

Bug Fix: Fixed regression that caused a false positive error when an overload implementation annotates a parameter with a union that includes a type variable.

Enhancement: Added support for type annotations that are enclosed in triple quotes.

Bug Fix: Fixed false positive error when a class declaration inherits from Protocol and Generic.

Bug Fix: Fixed bug that resulted in a missed error (false negative) when comparing an overload implementation with an overload signature that uses a generic return type.

Enhancement: Added support for a super() call made within a class method or instance method where the cls or self parameter is explicitly annotated (e.g. with a bound type variable).

Enhancement: Extended isinstance type narrowing logic to support Callable.

Enhancement (contribution from Matt Hillsdon): Reduced cascading parser errors when a colon is omitted before an indented code block.

Bug Fix: Fixed incorrect type evaluation for ternary, list and dictionary expressions in certain cases where the expression is within a loop.

Bug Fix: Fixed bug in control flow engine that resulted in incomplete types in certain cases that involved loops and circular type dependencies.

pyright - Published 1.1.166

Published by erictraut about 3 years ago

Bug Fix: Fixed a false positive error (and crash) when a walrus operator (assignment expression) is used within a list comprehension which is passed as an argument to a function decorator.

Bug Fix: Fixed stack overflow crash in type analyzer.

Bug Fix: Fixed incorrect evaluation of recursive type alias whose definition uses a TypeAlias annotation.

Enhancement: Improved error messages for type argument count mismatch; they were referring to a "class", but sometimes they were used for type aliases as well.

Bug Fix: Fixed bug that resulted in the incorrect specialization of a type alias that includes a ParamSpec.

Bug Fix: Fixed bug in type verifier that resulted in incorrect reporting of an unknown type when a type alias was defined using a TypeAlias annotation.

Enhancement: Extended dataclass_transform mechanism to support implicit init argument values for field descriptors.

Bug Fix: Fixed false native that incorrectly allowed a union type to be assigned to a constrained TypeVar.

Bug Fix: Improved handling of class properties (i.e. properties that have @classmethod applied to them). The cls parameter for the property method is now properly passed the class as an argument.

Enhancement (contribution by Marc Mueller): Adjust auto-import sorting to better match isort.

Bug Fix: Fixed bug in overlapping overload detection logic that resulted in false positives in some cases.

Bug Fix: Fixed a bug that resulted in unsolved TypeVars in certain edge cases involving function type compatibility checks.

Bug Fix: Improved handling of constrained type variables that use a union in one or more constraints.

Bug Fix: Fixed bug that resulted in a false positive error when a call involves overloads and one or more of the arguments involves another call expression whose type is generic, and therefore influenced by bidirectional inference context.

pyright - Published 1.1.165

Published by erictraut about 3 years ago

Bug Fix: Fixed false positive error due to incorrect type of the __doc__ instance variable. It should be str | None, but it was hard-coded to be str.

Bug Fix: Fixed a bug that resulted in a false positive type error when an instance variable's type depended on itself in a circular reference within a loop.

Bug Fix: Fixed false positive error when a binary operation uses None on the LHS and the RHS is a type that accepts None to a reverse operator overload method.

Bug Fix: Improved logic that determines whether a type is iterable. The old logic didn't support unions of iterable types.

Bug Fix: Improved handling of call expressions to functions that return NoReturn.

Bug Fix: Fixed bug in recently-added type check for inherited class variable type. The check was not properly specializing the base class type.

Enhancement: Updated typeshed stubs to the latest version.

Enhancement: Added performance optimization for code flow analysis within loops.

Enhancement (from Pylance): Don't offer keywords as completion suggestions if they are not valid for the currently-selected version of Python.

Enhancement: Added check for subscripted form of asyncio.Task when used in certain contexts prior to Python 3.9 that generate runtime exceptions.

pyright - Published 1.1.164

Published by erictraut about 3 years ago

Bug Fix: Fixed false positive error when assigning an Any value to a member of an object that has a __set__ method.

Enhancement: Eliminated confusing error message when nested argument expression contains a type error.

Enhancement: Improved bidirectional inference logic for lambda expressions to better handle the situation where the "expected type" is a union that contains multiple callable types.

Behavior Change: Suppressed the "obscured symbol" diagnostic check when the name of the symbol is _. This symbol is used in the single dispatch pattern documented in PEP 443.

Bug Fix (from Pylance): Support eggs that are not in zip files but are instead in folders.

Enhancement (from Pylance): Support pth file in extra paths.

Bug Fix: Fixed false positive error when a constrained TypeVar is used as the second argument to an isinstance or subclass call.

Bug Fix: Fixed false positive error that occurs when a @final class derives from an abstract base class that defines no abstract methods.

Bug Fix: Fixed false positive error related to overload implementation checks when the return type of the implementation contains a Tuple annotation with a TypeVar as a type argument.

Enhancement: Added special-case handling for tuple[()] type when determining the iterated type. In this case, it can be safely evaluated as Never.

Enhancement: Improved error reporting for assignments to class variable assignments within a child class where the assigned value doesn't match the type of the same-named class variable declared in a parent class.

pyright - Published 1.1.163

Published by erictraut about 3 years ago

Bug Fix: Fixed false positive error relating to the use of a *P.args or **P.kwargs parameter as an iterable value (where P is a ParamSpec).

Bug Fix: Fixed false positive error due to incomplete tracking of incomplete types during code flow evaluation.

Bug Fix: Fixed bug with ParamSpec matching in the case where the matched function contains parameters with default values or *args / **kwargs;

Bug Fix: Fixed false positive error that results when defining a property setter within an abstract base class and the property setter references a type that has a circular reference to the class.

Bug Fix: Fixed a false positive error when handling *args and **kwargs arguments when the function contains *P.args and **P.kwargs parameters.

Behavior Change (from Pylance): When inserting new auto-import symbol, sort by symbol type to match isort default behavior.

Bug Fix: Fixed comparison operators so they use the proper opposite when looking for a type match. For example, the opposite of __lt__ is __ge__ rather than __gt__.

Bug Fix: Fixed bug that caused inappropriate type narrowing if a comparison operator was used within an argument for a call expression which was, in turn, used within an if condition expression.

Behavior Change: Changed the interpretation of a "callback protocol" to encompass protocols that include a __call__ method in addition to other attributes.

Bug Fix: Fixed false positive error related to with statements with an expression enclosed in single parentheses.

Bug Fix: Fixed bug in type var matching when the a cls parameter is annotated with type Type[T] and T is bound to a protocol class.

Bug Fix: Fixed bug that resulted in # type: ignore comments to be ignored in the event that we hit the heap high-water mark and emptied internal caches.

Enhancement: Updated to latest version of typeshed stubs.

pyright - Published 1.1.162

Published by erictraut about 3 years ago

Enhancement: Added support for unpacking of objects that derive from known-length tuples. This includes named tuples.

Enhancement: Improved match statement code flow logic to handle the case where a pattern is exhausted prior to the last case statement.

Enhancement: Improved "implied else" code flow logic to handle nested "implied else" constructs.

Bug Fix: Fixed regression that affected type narrowing of subscript expressions for TypedDict objects.

Bug Fix: Fixed false positive error caused by inappropriate method binding for instance methods.

Enhancement (from pylance): Added more support in completion provide for literal expressions.

Bug Fix: Changed registration of language server to allow for URI types other than files. This allows pyright to be activated when an untitled file is identified as a python source file.

Bug Fix: Fixed false positive error when assigning to a subscript expression where the base type is a TypedDict.

Bug Fix: Fixed false positive error when "*P.args" parameter (where P is a ParamSpec) is passed as an argument to another function that accepts "P.args".

Bug Fix: Added support for member access expressions where the attribute contains a class whose metaclass implements a descriptor protocol.

Bug Fix: Fixed crash due to infinite recursion when a protocol class included a property getter that returned an instance of the same protocol class.

Enhancement: Improved the readability of error messages related to protocol type mismatches.

Bug Fix (from pylance): Fixed diagnostics for source files that are not on disk (e.g. "untitled" new documents).

Enhancement (from pylance): Added support for attribute docstrings in hover text.

pyright - Published 1.1.161

Published by erictraut about 3 years ago

Bug Fix: Fixed bug in declaration provider that caused declaration not to be found when it referred to a metadata method.

Bug Fix: Fixed bug that resulted in a false when evaluating nested lambdas (i.e. a lambda that returns a lambda).

Enhancement: Added support for bidirectional type inference for assignment expressions where the LHS is an index expression that indexes into a TypedDict instance.

Enhancement: Added support for new type narrowing pattern for discriminating among tuples. The pattern is V[I] == L or V[I] != L where I is an integer literal, L is another literal value, V is a tuple with a known length and a type at index I that is declared as a literal type.

Enhancement: Improved logging for import failures. The previous code was printing the same log message for both stub and non-stub package resolution attempts which resulted in seemingly redundant messages.

Enhancement: Added heuristic to allow proper inference of list expressions when used as the RHS operand in an expression of the form my_list + [x].

Bug Fix: Fixed a bug that was masking some error messages when multiple errors were reported for the same range and their message started with the same 25 characters.

Enhancement: Changed method and attribute override compatibility checks to check for inappropriate overrides of all base classes in the multi-inheritance case. Previously, this check used MRO, so some override mismatches were left unreported if they were obscured by another base class. The change also affects @final checks.

Enhancement: Added support for descriptor protocols defined on metaclasses.

Bug Fix: Fixed a bug that caused methods in generic classes to be specialized twice when accessed through a member access expression.

Bug Fix: Fixed false positive error when accessing __name__ instance variable in a class that derives from type.

Enhancement: Updated typeshed stubs to the latest version.