microsoft /pyright
Static Type Checker for Python
★ 15,749⑂ 1,853👁 125⑃ 2,817● 7,649▤ 495
More from this author
+1
Daily
15,749
stars
1,853
forks
125
watchers
2,817
prs
7,649
issues
495
releases
README
!Pyright Static Type Checker for Python Pyright is a full-featured, standards-based static type checker for Python. It is designed for high performance and can be used with large Python source bases. Pyright includes both a command-line tool and an extension for Visual Studio Code. Pyright Playground Try Pyright in your browser using the Pyright Playground. Documentation Refer to the documentation for installation, configuration, and usage details. Performance The weekly type checker benchmark compares Pyright with other Python type checkers. The Pyright release history tracks per-package execution time and peak memory across releases. Environment variables If Pyright fails to create a temporary directory (for example in remote/server environments where the OS temp directory doesn't exist or isn't writable), you can override the temp directory root: - PYRIGHT_TMPDIR: Absolute path to a directory that Pyright can use for temporary files/directories. Pyright will create it if needed. Pyright otherwise relies on the platform temp directory (for example TMPDIR, TMP, TEMP, or the OS default). Community Do you have questions about Pyright or Python type annotations in general? Post your questions in the discussion section. If you would like to report a bug or request an enhancement, file a new issue in either the pyright or pylance-release issue tracker. In general, core type checking functionality is associated with Pyright while language service functionality is associated with Pylance, but the same contributors monitor both repos. For best results, provide the information requested in the issue template. Contributing This project welcomes contributions and suggestions. For feature and complex bug fix contributions, it is recommended that you first discuss the proposed change with Pyright’s maintainers before submitting the pull request. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com. When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA. This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.
Top issues
#11076Process never finishes in `1.1.405`, `1.1.406`, `1.1.407`, `1.1.408`10 comments · 2025-10-30#10910Pyright fails on files that are too large9 comments · 2025-09-09#10881Consuming large amount of heap memory8 comments · 2025-09-02#10805Remove unsafe type narrowing for non-closed TypedDicts8 comments · 2025-08-15#11989Inherited self-annotated `__init__` overload does not solve a generic subclass's type parameters7 comments · 2026-11-07#11528Numpy dtype.names seen as None7 comments · 2026-06-27#10850bug: spurious "partially unknown"7 comments · 2025-08-26#10329False positive unreachable with unrelated types in match-case statement7 comments · 2025-04-15
Discussions
#11979Request to review a PR wrt namespaces bug1 comments · 2026-11-05#11792`io.BufferedReader`: typeshed vs Python documentation2 comments · 2026-09-21#11629Is it possible to use Pyright to get semantic tokens for Python?1 comments · 2026-08-12#11618Asymmetric descriptor type apparently overriden when descriptor is set within the class body1 comments · 2026-08-11#11557Type Narrowing in Closures2 comments · 2026-07-22#11554Detect redundant type conversion2 comments · 2026-07-20#11553Supporting Self references to class-scoped type aliases?1 comments · 2026-07-19#11545Protocol doesn't seem to agree with SQLAlchemy `Mapped` attributes1 comments · 2026-07-14
Latest release
Published 1.1.414 1.1.414 2026-09-09Changes: a28cce4077d87b80bead12de809f79845e39c8ba Bump version to 1.1.414 (11724) 10f9e773c012d3ae15fd3232915a86ffda64d371 Bump the github-actions group across 1 directory with 5 updates (11720) d72e2fe89e4ad4227d6c5be9bb6e57b082768e23 Fix pnpm setup in benchmark workflow (11719) 854df36c470a636ca44fbf222ea7d4f328f5f471 Allow assigning signature metadata to functions (11714) c77393240247e017db6538d35876e723c518e06c Publish pyright-typeserver to npm (11713) fa9b200906fadc093e862ce62ec1afa985c7233d Pull Pylance with Pyright 1.1.413 (11697) e690634a94ab05cf7dd003b63b1ac67cd6d6878e Fix pri