github microsoft/pyright 1.1.254
Published 1.1.254

latest releases: 1.1.388, 1.1.387, 1.1.386...
2 years ago

Enhancement (from Pylance): Use new detail description feature added in 3.17 LSP to show full module path for auto import.

Bug Fix (from Pylance): Make sure file watcher treats a zip file as a file not folder.

Enhancement: Added code to detect and flag usage of # type: xxx comments for for and with statements.

Enhancement: Added new configuration setting called "defineConstant". It allows a configuration to specify one or more identifiers that should be assigned by pyright's binder to be constant anywhere they appear. Values can be boolean (true or false) or a string. If an identifier of this value is used within a conditional statement (like if not DEBUG:) it will affect pyright's reachability analysis for the guarded code blocks.

Bug Fix: Fixed bug that resulted in a false negative when attempting to call pop on a TypedDict with a key that is required.

Enhancement: Added support for new reportTypeCommentUsage diagnostic check. It flag the usage of # type: xxx comments for functions and variables. These are still supported for backward compatibility, but they are increasingly irrelevant and will likely be deprecated in the next few years.

Bug Fix: Fixed a bug that resulted in a false negative when a variable with a declared type is overwritten by an incompatible type by an import statement.

Enhancement: Added code to print the pyright version as part of the CLI output. This is useful for diagnosis.

Bug Fix: Undid previous fix related to circular class dependency detection because it introduced a regression with sqlalchemy stubs. Implemented a different solution to detect circular class dependencies and handle them correctly.

Bug Fix: Changed the handling of partial stub packages to conform with PEP 561. They should always overlay the original package even if that package is marked "py.typed".

Bug Fix: Fixed bug in tokenizer that results in incorrect tokenization when a hex numeric literal is followed by a newline followed by either a 'b' or 'o' character.

Don't miss a new pyright release

NewReleases is sending notifications on new releases.