NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
PyPI, #1250 most downloaded on PyPI
A fast type checker and language server for Python with powerful IDE features
Latest stable
1.4.1
Last release 14 days ago
05 Nov 2026
Ships on a steady schedule
a new release about every 2 weeks
Most releases are documented
notes for 40 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
2 years old
154 releases · first in 2025
Drag across the ruler to compare, or tap a release to open it.
Status : ALPHA *Release date: 27 October 2025*
Status : ALPHA
Release date: 27 October 2025
Pyrefly v0.39.0 bundles 195 commits from 19 contributors
| Area | What’s new |
|---|---|
| Inheritance checks | - Added additional inheritance checks for typed dictionaries <br><br> - Pyrefly no longer throws duplicate errors for overridden fields <br><br> - Multiple inheritance checks are now skipped for some special fields, such as constructors |
| Language Server | - Major improvement on startup time for IDE features. This change makes most IDE features available instantly, with completions being available a few seconds later in large environments with hundreds of site-packages <br><br> - Pyrefly can now update imports when files are renamed, by handling will_rename_file , a request sent by the language client when files are renamed. <br><br> - Add semantic highlighting and hover docstrings in the Pyrefly website sandbox <br><br> - Better IDE support for files that don’t have a marker file (pyproject.toml / pyrefly.toml), making operations like find-references should now work in almost every case |
| Build Systems | Improved handling of namespaced directories in build systems. Pyrefly now keeps track of namespaces (directories with a python or source file, but no __init__) in the build system, then returns them for Pyrefly to work with |
| Docs & error messages | - Improved no-matching-overload errors. When no overload matches a function call, Pyrefly now displays the actual argument types that were provided. This eliminates the need to hover over each argument to understand why the call failed. <br><br> - New error kind untyped-import added to detect missing Django stubs. This error is ignored by default; see the configuration docs for how to enable it. <br><br> - Improved Pydantic documentation to explicitly list supported features. |
We closed 10 bug issues this release 👏
__bool__ check not working properly with unionsStrEnum imports not working properlyunbound-name errors erroneously thrown in try, except blockssite-packages directory contains a large number of additional packagesThank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.39.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyefly documentation
@yangdanny97, @stroxler, @connernilsen, @kinto0, @migeed-z, @arthaud, @rchen152, @tianhan0, @samwgoldman, @lolpack, @Adist319, @asukaminato0721, @fangyi-zhou, @immanuel-peter, @jvansch1, @javabster, @pawelstrzmeta, @rubmary,
Your coding agent can read these notes before it upgrades. Set up the MCP server →
Nothing published for this version
Nothing published for this version
Improved handling of deprecated dunder methods and ensured consistent error messages.
Status : ALPHA
Release date: 2025-10-21
Pyrefly 0.38.0 bundles 126 commits from 14 contributors. This release brings major improvements to typechecking, error reporting, IDE integration, and configuration flexibility, along with a host of bug fixes and performance enhancements.
| Area | What’s new |
|---|---|
| Type System | - Flow-merging now respects explicit and implicit Any, preventing catastrophic type unions in gradual codebases.<br>- Added off-by-default error for implicit Any (missing param/return annotations, empty containers).<br>- Improved handling of strict types and propagation of strictness in type aliases and class bases. |
| Error Reporting | - Diagnostics now include clickable links to error documentation.<br>- Improved error messages for Protocol & TypedDict mismatches, abstract async iterators, bad tuple subscriptions, and failed x in y checks.<br>- Renamed several error kinds for clarity (import-error → missing-import, async-error → not-async, delete-error → unsupported-delete, index-error → bad-index, match-error → bad-match, type-alias-error → invalid-type-alias).<br>- Added a severity field to JSON output. |
| IDE & LSP | - Unannotated and annotated local variables now appear in VSCode's symbol table.<br>- Inlay hints and type inference for Any/Unknown are suppressed for clarity.<br>- Module import completions and quick fixes improved.<br>- Hovering over # pyrefly: ignore now shows the error that is suppressed by that comment.<br>- Renaming files will now update imports that reference those files. |
| Performance & Config | - Faster file globbing and directory scanning.<br>- Default exclusion of hidden directories.<br>- Improved config override handling for CLI and IG commands.<br>- Added warning when running pyrefly check on ~ (home directory). |
We closed 12 bug issues this release 👏
Notable bug fixes include:
in checks.import a and from a import b.with and except blocks.--remove-unused-ignores feature.for ... else.Thank you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.38.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyrefly documentation
@arthaud, @stroxler, @yangdanny97, @abdallhfattah, @kinto0, @rchen152, @samwgoldman, @migeed-z, @connernilsen, @grievejia, @asukaminato0721, @rubmary, @Adist319, @johnvanschultz
If you have any questions or feedback, please open an issue or join the discussion on GitHub. Thank you for using Pyrefly!
Pyrefly 0.37.0 bundles 198 commits from 15 contributors. This release brings major improvements to typechecking control flow, overload resolution, Dja
Status : ALPHA
Release date: 2025-10-14
Pyrefly 0.37.0 bundles 198 commits from 15 contributors. This release brings major improvements to typechecking control flow, overload resolution, Django/enum support, and more.
| Area | What’s new |
|---|---|
| Control Flow & Type Narrowing | Improve type narrowing across if/else, match, boolean ops, and loops. This enables more precise type inference and fixes several long-standing false positives and negatives. |
| Overload Resolution | Fully implemented the Python typing spec for overload call evaluation, including argument type expansion for unions, bools, enums, tuples, and type. Overloads are now filtered by argument count and variadic-ness, with better error messages and performance. |
| Django & Enum Support | Enhanced Django model field type inference, improved enum attribute handling (including Django enums), and fixed bugs with auto(), Choices, and mixed-in enum data types. |
| LSP & Editor Features | Added inlay hints for function argument names, docstrings for attribute and variable completions, and improved workspace folder detection for LSP clients. |
We closed 12 bug issues this release 👏
Thank you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.37.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyrefly documentation
@stroxler, @yangdanny97, @arthaud, @connernilsen, @rchen152, @migeed-z, @grievejia, @fangyi-zhou, @kinto0, @fatelei, @ndmitchell, @brosenfeld, @dtolnay, @John Van Schultz
Thank you to everyone who contributed code, bug reports, and feedback!
Full changelog: Comparing 0.36.0...0.37.0
Nothing published for this version
Nothing published for this version
Pyrefly v0.36.0 bundles 150 commits from 23 contributors . This release brings major improvements to performance, type checking, and Pydantic/Django s
<html><head></head><body><h1>Pyrefly v0.36.0</h1> <p><strong>Status : ALPHA</strong> </p> <p><em>Release date: 2025-10-06</em></p> <p>Pyrefly v0.36.0 bundles <strong>150 commits</strong> from <strong>23 contributors</strong>. This release brings major improvements to performance, type checking, and Pydantic/Django support, along with numerous bug fixes and a brand new baseline feature.</p> <hr> <h2 id="newimproved">✨ New & Improved</h2>
| Area | What’s new |
|---|---|
| Performance | With #360 solved, Pyrefly is much faster on projects & environments with a large number of dependencies. |
| Baseline Feature | A new experimental baseline mechanism to store existing errors in a separate file. See the docs for more info. |
| Control Flow & Type Narrowing | Major improvements to how we model control flow and type narrowing, reducing false-positive errors. Builtin types can now be narrowed to literals in more situations. |
| LiteralString | Added support for LiteralString in format(), join(), and replace() methods. |
| Pydantic | Enhancements and bug fixes were made to the experimental Pydantic support released last month. Pydantic's docs now contains documentation for how to use Pyrefly with Pydantic! |
| Django | Progress on experimental support for Django fields and enums. |
| IDE | Bug fixes for auto-import quick fix, improved hover info format to improve readability, reduce clutter, and enable syntax highlighting for function types. |
| Sandbox | Browser sandbox now supports Python stub files (.pyi). |
<hr> <h2 id="bugfixes">🐛 Bug Fixes</h2> <p>We closed 20 bug issues this release 👏</p>
#264,#360,#528,#657,#683,#778,#790,#812,#969,#1009,#1022,#1042,#1088,#1162,#1198,#1210,#1218,#1227,#1228,#1235
<p>Thank you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue <a href="https://github.com/facebook/pyrefly/issues">here</a></p> <hr> <h2 id="upgrade">📦 Upgrade</h2> <pre><code class="bash language-bash">pip install --upgrade pyrefly==0.36.0 </code></pre> <h3 id="howtosafelyupgradeyourcodebase">How to safely upgrade your codebase</h3> <p>Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:</p> <ol> <li><code>pyrefly check --suppress-errors</code> </li> <li>run your code formatter of choice </li> <li><code>pyrefly check --remove-unused-ignores</code> </li> <li>Repeat until you achieve a clean formatting run and a clean type check.</li> </ol> <p>This will add <code># pyrefly: ignore</code> comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.</p> <p>Read more about error suppressions in the <a href="https://pyrefly.org/en/docs/error-suppressions/">Pyrefly documentation</a></p> <hr> <h2 id="contributorsthisrelease">🖊️ Contributors this release</h2> <p>@stroxler, @arthaud, @samwgoldman, @connernilsen, @migeed-z, @rchen152, @grievejia, @ndmitchell, @yangdanny97, @AryanBagade, @rubmary, @cjlongoria, @simonhollis, @MarcoGorelli, @mohesham88, @Viicos, @Adist319, @airvzxf, @BrianRosenfeld, @IvanLoskutov, @ahornby, @kinto0</p> <hr> <p><a href="https://github.com/facebook/pyrefly/compare/0.35.0%E2%80%A60.36.0#js-repo-pjax-container">Skip to content</a></p> <hr> <p><strong>If you need more details on any change, see the <a href="https://github.com/facebook/pyrefly/compare/0.35.0%E2%80%A60.36.0">full commit log</a>.</strong></p></body></html>
| Security | - upgraded mdbook crate to 0.4.52 to resolve vulnerability with ammonia dependency |
Status : ALPHA
Release date: 29 September 2025
Pyrefly v0.35.0 bundles 226 commits from 18 contributors.
| Area | What’s new |
|---|---|
| Configuration | - Improved config finding, preferring Pyrefly configurations in any parent directory to project root marker files. pyproject.toml files are now only considered configurations when a [tool.pyrefly] section is present, otherwise, they are root marker files. |
| Build systems | - Continued work on build system support, primarily Buck. Look out for further updates coming soon! |
| Error messages and suppressions | - Improved reveal_type/assert_type error messages to suggest importing from typing when needed, rather than a generic “could not find name” error message <br><br>- New error kind introduced: inconsistent-overload. This gives overload consistency errors a separate error kind from other invalid overload errors so that users can turn off consistency checks if they wish. suppress-error command now has optional --same-line argument for easier bulk suppression of errors. Instead of adding pyrefly ignore comments on the line above, this flag adds the comment on the same line as where the error is. |
| Security | - upgraded mdbook crate to 0.4.52 to resolve vulnerability with ammonia dependency |
| Third party package support | - Improved handling of optional Pydantic fields (if they are optional we should not require them) <br><br>- Foundational work to support Django enums |
We closed 11 bug issues this release 👏
type(x) returning the wrong thingSession context manager from SQL Alchemy. Fixing this issue brings us one step closer to Pyrefly being full usable SQL Alchemy (follow progress here)Thank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.35.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyefly documentation
@javabster, @samwgoldman, @grievejia, @kinto0, @rchen152 , @yangdanny97, @tianhan0, @stroxler, @SamChou19815, Carlos Fernandez, @cjlongoria, @connernilsen, @maggiemoss, @arthaud, @mohesham88, @VladimirMakaev, @migeed-z
- IDE autocomplete now displays if a method or function is deprecated -IDE autocomplete now escapes single quotes (’’) for autocomplete |
Status : ALPHA
Release date: 22 September 2025
Pyrefly v0.34.0 bundles 180 commits from 22 contributors.
| Area | What’s new |
|---|---|
| Type Parameter Handling | - Significant refactoring of internal logic for handling uninitialised variables, resolving multiple bugs in the process <br><br>- Support added for referring to imported legacy TypeVars by their fully qualified name (see example in sandbox) <br><br>- Support added for implementing protocols with generic methods. |
| IDE | - IDE logic has been refactored to limit concurrent recheck and find-references tasks, preventing excessive thread spawning under heavy workload and improving overall IDE responsiveness. <br><br>- IDE autocomplete now displays if a method or function is deprecated<br><br>-IDE autocomplete now escapes single quotes (’’) for autocomplete |
| Pyrefly Configs | - Users can now use negation when setting replace-imports-with-any . Eg. replace-imports-with-any: ["!sympy.printer", "sympy.*"] will replace any sympy imports with Any EXCEPT for sympy printer imports |
| Error Messaging | <br>- Improved how overload signatures in error messages are displayed to avoid printing confusing upper bounds of TypeVars |
| Documentation | <br>- IDE documentation updated to include Jupyter Lab information and improved inlay hint instructions. |
We closed 21 bug issues this release 👏
abstractmethod decorated functions issue caused literal types in signatures to be promoted incorrectlyTypeVars: #1050, #912, #129--watch CLI command now works again!Thank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.34.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add \# pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyefly documentation
@rchen152, @tianhan0, @ndmitchell, @yangdanny97, @stroxler, @arthaud, @SamChou19815, @grievejia, @javabster, @connernilsen, @cooperlees , @dluo, @dtolnay, @fangyi-zhou, @kinto0, @maggiemoss, Paul Iatchenii, @samwgoldman, @sandeshbhusal, @VladimirMakaev, @migeed-z
Nothing published for this version
Status : ALPHA *Release date: 15 September 2025*
Status : ALPHA
Release date: 15 September 2025
Pyrefly v0.33.0 bundles 117 commits from 21 contributors
| Area | What’s new |
|---|---|
| Type Checker Behavior | - Pyrefly now distinguishes between Any as a value and as a type, preventing incorrect attribute access and constructor calls on Any values. For example, when Any (the value) is used as an attribute base or call target pyrefly will now error if you try to access attributes that are not defined on type. <br>- Basic support added for TypeAliasType <br> Experimental support for Pydantic now available! <br>- Type error messages by default now print paths relative to working directory (as opposed to absolute path) |
| IDE improvements | - Kwarg completion now supports literals and unions of literals (requested feature) <br>- A new "typeServer/getSupportedProtocol" request handler included to fetch TSP version information |
| Website and Documentation | - The sandbox feature on the website has been upgraded! It can now deal with multiple files, allowing users to try out Pyrefly with cross-file imports. Give it a go here! <br>- New documentation guide on experimental Pydantic support, read it here <br>- New editable installs section in documentation, detailing the nuances of working with editable dependencies. Read it here. |
We closed 4 bug issues this release 👏
list[Self]bad-override error split into 2 separate error codes for type and name differences in argumentsThank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.33.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the [Pyefly documentation](https://pyrefly.org/en/docs/error-suppressions/)
@javabster, @stroxler, @grievejia, @ndmitchell, @fangyi-zhou, @samwgoldman, @rchen152, @kinto0, @connernilsen, @AryanBagade, Brian Rosenfeld, Carlos Fernandez, @yangdanny97, @hashiranhar, @IDrokin117, @maggiemoss, @rchiodo, @VladimirMakaev, @migeed-z
- The tracing-subscriber crate was updated from 0.3.19 to 0.3.20 to fix RUSTSEC-2025-0055, addressing a vulnerability related to ANSI escape sequence…
Status : ALPHA
Release date: 08 September 2025
Pyrefly v0.32.0 bundles 70 commits from 18 contributors
With this release type errors are now disabled by default in IDE when there is no config present ( in pyrefly.toml or pyproject.toml). This change was made based on feedback that displaying type errors by default in the IDE (i.e. red squiggles) was a nuisance for new users, especially those looking only for language services. Users are still able to enable type checking without a configuration file if they wish by updating their config (either in their pyproject.toml, pyrefly.toml or VSCode settings):
# to enable type errors
"python.pyrefly.displayTypeErrors": "force-on"
| Area | What’s new |
|---|---|
| Type Checker Behavior | - Implicit return validation is now performed even when untyped-def-behavior is set to check-and-infer-return-any for functions with explicit return annotations. This fixes a conflation issue where return type inference being disabled also disabled implicit return validation. <br><br>- Improved handling of calls on type[...] including cls (typed as type[Self]). <br><br>- Deprecation warnings are now emitted when a deprecated function is referred to, not just called. Scoping for class fields in nested scopes is now correctly handled. |
| IDE Integration | - Type errors now disabled by default in IDE (see details above). <br><br>- Users can now see in their IDE status bar whether the current file has type errors enabled/disabled <br><br>- Improved hover for Union types, so hover display now merges identical elements. |
| Build Systems & Security | - Further improvements made to emulate Buck’s build system file mappings within Pyrefly. This improves Pyrefly's integration with various build systems in OSS and IDEs, though build system support is still in progress. <br><br>- The tracing-subscriber crate was updated from 0.3.19 to 0.3.20 to fix RUSTSEC-2025-0055, addressing a vulnerability related to ANSI escape sequence injection attacks in logs. |
We’ve closed 10 bug issues since our last minor release 👏
LiteralThank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.32.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyefly documentation
@rchen152, @dtolnay, @kinto0, @samwgoldman, @SamChou19815, @grievejia, @migeed-z, @yangdanny97, @arthaud, @tianhan0, @AryanBagade, @asukaminato0721, Carlos Fernandez, @connernilsen , @fangyi-zhou , @hashiranhar, @VladimirMakaev
Nothing published for this version
Status : ALPHA *Release date: 02 September 2025*
Status : ALPHA
Release date: 02 September 2025
Pyrefly v0.31.0 bundles 69 commits from 19 contributors
| Area | What’s new |
|---|---|
| PEP 728 support | - extra_items is now fully supported, with these changes support for PEP 728 is now complete! 🚀 |
| LSP Features | - Introduced Pylance config python.analysis.importFormat, with possible values ”absolute” and ”relative”. <br><br> - The default "absolute" maintains the current behavior, while "relative" enables importing modules using relative paths server name and version string now returned during LSP initialisation, useful for LSP clients for debugging/logging. <br> |
| Type Narrowing | - Improved narrowing for getattr(...) Narrow hasattr with string literals to Any if the attribute does not already exist |
| Inference & autocomplete | - Improved inference for self annotation: inferred to be type[Self] when decorated with classproperty or lazy_classproperty. <br><br> - Improved autocomplete for imports with addition of import keywords. (Previously from x imp… would autocomplete to from x import imp) <br> |
| Build System Integration | - Standalone pre-commit hook now available, see updated docs here <br><br>- Refactored Buck build functionality into a new pyrefly_build crate. This does not involve functional changes but lays the groundwork for future work to enable Pyrefly to work more effectively with various build systems in both OSS and IDE environments. |
| Conformance | - Pyrefly has now been added to the conformance test suite, enabling users to compare behaviour of static type checkers against expectations defined in the Python typing specification |
We closed 12 bug issues this release 👏
type[T].__new____all__ mutation without definitionunittest.main()Thank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.31.0
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyefly documentation
@lolpack, @aahanaggarwal, @donsbot, @kinto0, @stroxler, @rchen152, @grievejia, @brosenfeld, @yangdanny97, @SamChou19815, @migeed-z, @connernilsen, @tianhan0, @javabster, @PIG208, @samwgoldman, @IDrokin117, @maggiemoss, @arthaud , @melvinhe, @rchiodo, @VladimirMakaev
Status : ALPHA *Release date: 25 August 2025*
Status : ALPHA
Release date: 25 August 2025
pyrefly v0.30.0 bundles 195 commits from 20 contributors 👏
| Area | What’s new |
|---|---|
| Completions | - Enhanced completions for super with multiple inheritance implemented completion for unions <br><br>- When the attribute base is a union, suggestions are now combined from every branch of the union. This might lead to errors, but it's more helpful to make the suggestion |
| Type System | - added a configuration flag to turn off "infer from first use" behavior. Inferring types from first usage is valuable for catching bugs but it can lead to false positives so this new flag allows users to turn it off. Turning it off behaves like pyright, leaving it on behaves like mypy. <br><br>- implicit attribute definition errors are now turned off by default. These errors were raised when an attribute is only declared in a non-constructor method, but it can be a source of false positives in dynamic code. <br><br>- When type args are not explicitly set, push the class type params into methods (matches mypy approach, differs from pyright that implicitly instantiates with Any/default) ensured qualified names are printed for enums as part of unions. <br><br>- Enable creation of empty enums and named tuples using functional syntax Default excludes now align with Pylance (incl. Node_modules, __pycache__ and *venv) |
We closed 11 bug issues this release 👏
Never, rather than Anytorch.zeros moduleSelfThank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.30
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
pyrefly check --suppress-errorspyrefly check --remove-unused-ignoresThis will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the Pyefly documentation
@javabster, @capickett, Carlos Fernandez, @connernilsen , @yangdanny97, @grievejia, @kinto0, @arthaud, @prasannavenkateshgit, @rchen152, @rchiodo, @rubmary, @samwgoldman, @SamChou19815, @sargun, @stroxler, @VladimirMakaev, @migeed-z, @LycheeBay
Nothing published for this version
Nothing published for this version
Status : ALPHA Release date: 18 August 2025
Status : ALPHA Release date: 18 August 2025
Pyrefly 0.29 bundles 192 commits from 23 contributors. This release focuses on improving the type checker's behavior, particularly around handling Any and LiteralString, enhancing LSP features like "go to definition" and hover, and various internal refactors for maintainability.
| Area | What’s new |
|---|---|
| Type Checker Behavior | - The type checker now treats return outside of a function, and await, async for, async with outside of async function definitions as syntax errors.<br>- Support special LiteralString behavior for methods like str.join and str.format.<br>- Any handling for super().__init__ and super().__new__ calls have been improved.<br>- typing.Self is now correctly substituted inside method bodies.<br>- Using the new PEP 728 keywords (closed, extra_items) in TypedDict no longer throws type errors.<br>- Full support for PEP 728 is coming soon. |
| LSP Features | - "Go to definition" now prioritizes .py files over .pyi for a more useful real implementation view.<br>- Docstrings now appear for standard library functions.<br>- Display ranges for generator expressions have been adjusted for consistency with Python AST. |
We closed 21 bug issues this release 👏
Thank-you to all our contributors who found these bugs and reported them! Did you know this is one of the most helpful contributions you can make to an open-source project? If you find any bugs in Pyrefly we want to know about them! Please open a bug report issue here
pip install --upgrade pyrefly==0.29
Upgrading the version of Pyrefly you're using or a third-party library you depend on can reveal new type errors in your code. Fixing them all at once is often unrealistic. We've written scripts to help you temporarily silence them. After upgrading, follow these steps:
1. pyrefly check --suppress-errors
2. run your code formatter of choice
3. pyrefly check --remove-unused-ignores
4. Repeat until you achieve a clean formatting run and a clean type check.
This will add # pyrefly: ignore comments to your code, enabling you to silence errors and return to fix them later. This can make the process of upgrading a large codebase much more manageable.
Read more about error suppressions in the [Pyefly documentation](https://pyrefly.org/en/docs/error-suppressions/)
Aahan Aggarwal, Abby Mitchell, Conner Nilsen, Danny Yang, David Luo, Fangyi Zhou, James Gill, Kc Balusu, Kyle Into, LyricalToxic, Maggie Moss, Maxime Arthaud, Neil Mitchell, Rebecca Chen, Rubmary Rojas, Sam Goldman, Sam Zhou, Steven Troxler, Vladimir Matveev, Xavi Simpson, Zach Riser, Zeina Migeed
Nothing published for this version
pyrefly v0.28 bundles 119 commits from 20 contributors. This release introduces new features related to function and class metadata, improves class ba
pyrefly v0.28 bundles 119 commits from 20 contributors. This release introduces new features related to function and class metadata, improves class base type calculations, enhances import finding logic, and addresses several bug fixes related to LSP behavior, error reporting, and type inference.
| Area | What’s new |
|---|---|
| Type Checker | Export function information including names and locations, enabling Pysa to use pyrefly's function list for consistency.Add parent information to functions and classes to facilitate unique fully qualified name generation in Pysa.Introduce function flags (e.g., is_overload, is_classmethod) for richer metadata. |
| Class Metadata & Type Inference | Support Pydantic metadata by adding it to class metadata. |
| Import Resolution | Implement preference for .pyi files over .py over .pyc files in import finding, even if the import occurs later in the includes list. This is particularly useful for go-to-definition in the LSP, preferring implementation files over interfaces. |
| Error Reporting | Add a check for unused coroutines, similar to pyright and mypy, to flag coroutines that are not awaited, passed to a function, or assigned to a variable. |
| LSP | Improvements to LSP shutdown behavior, ensuring the language server exits gracefully on connection close and removing previous workarounds for exit notifications. |
| Configuration | Add support for ignore files (.gitignore, .ignore, .git/exclude) with a config (use-ignore-files) to enable and disable their use. |
| Website Sandbox | Added a dropdown to select the Python version in the sandbox, allowing users to test against different Python versions (3.8-3.12). |
If you are using Pyrefly in your CI processes, the following changes may cause your CI to break when upgrading to the new version of Pyrefly
To upgrade to the latest version of Pyrelfy, run the following terminal command:
pip install --upgrade pyrefly==0.28
Thank-you to all our wonderful contributors!
Aaron Pollack, Abby Mitchell, Adist319, Carlos Fernandez, Conner Nilsen, Danny Yang, Doğaç Eldenk, Fangyi Zhou, Jia Chen, Kyle Into, Maggie Moss, Maxime Arthaud, Neil Mitchell, Rebecca Chen, Rubmary Rojas, Sam Goldman, Sam Zhou, Xavi Simpson, Zeina Migeed
Nothing published for this version
Nothing published for this version
Pyrefly 0.27.0 bundles 212 commits from 20 contributors
Status: ALPHA
Release date: 2025-08-04
Pyrefly 0.27.0 bundles 212 commits from 20 contributors
Typechecking
except clauses.x: int) are no longer always assumed uninitialized.UsageLink ranges by using YieldLink for yield calculations.__path__ to MutableSequence.IDE
__new__/__init__ calls are treated as overloads.cls arguments are removed from completion and signature help.displayName in package.json.Misc.
pip install --upgrade pyrefly==0.27.0
@stroxler @fangyi-zhou @rubmary @kinto0 @grievejia @rchen152 @ndmitchell @aahanaggarwal @javabster @connernilsen @migeed-z @SamChou19815 @yangdanny97
Full Changelog: https://github.com/facebook/pyrefly/compare/0.26.0..0.27.0
Nothing published for this version
Warn on calling deprecated overloads.
Status: ALPHA
Release date: 2025-07-28
Pyrefly 0.26.0 bundles 179 commits from 24 contributors
pip install --upgrade pyrefly==0.26.0
@grievejia @samwgoldman @stroxler @rchen152 @fangyi-zhou @ndmitchell @rubmary @kinto0 @arthaud @lolpack @migeed-z @darricklaidin @connernilsen @regexyl @danielocfb @WeixiMa @MaggieMoss @yangdanny97
Full Changelog: https://github.com/facebook/pyrefly/compare/0.25.0..0.26.0
Nothing published for this version
Warn on deprecated method calls and overloaded calls.
Status: ALPHA
Release date: 2025-07-22
Pyrefly 0.25.0 bundles 307 commits from 19 contributors
typing.Self.ignore_missing_imports in Pyrefly config.TypedDict initialization & makeself positional-only.pip install --upgrade pyrefly==0.25.0
@rchen152 @stroxler @ndmitchell @yangdanny97 @arthaud @kinto0 @connernilsen @SamChou19815 @rubmary @dluo @migeed-z @samwgoldman @fangyi-zhou @LyricalToxic @melvinhe @grievejia @lolpack
Full Changelog: https://github.com/facebook/pyrefly/compare/0.24.2...0.25.0
Pyrefly 0.24.2 bundles 290 commits from 26 contributors
Status: ALPHA
Release date: 2025-07-15
Pyrefly 0.24.2 bundles 290 commits from 26 contributors
type() and bool() for narrowing, and the behavior for match statements w/ class patternsdataclass_transform--error, --warn, --ignore) and improved error message clarity.float * bool and complex * bool.--typeshed-path CLI flag for custom typeshed modifications and improved config handling logic.pip install --upgrade pyrefly==0.24.2
@ndmitchell, @yangdanny97, @stroxler, @rchen152, @migeed-z, @connernilsen, @dluo, @MaggieMoss, @rubmary, @xaskii, @kinto0, @grievejia, @SamChou19815, @melvinhe, @lianne, @krikera, @dluo, @Abel981, @fangyi-zhou, @Alex-Aron, @zpao, @slawlor, @diliop, @arnav-jain1, @samwgoldman
Nothing published for this version
Nothing published for this version
Nothing published for this version
Status: ALPHA *Release date: 2025-07-07*
Status: ALPHA
Release date: 2025-07-07
Pyrefly 0.23.0 bundles 186 commits from 24 contributors. This release introduces significant improvements in type checking, configuration handling, and error management.
pip install --upgrade pyrefly==0.23.0
@aahanaggarwal, @yangdanny97, @stroxler, @rchen152, @dluo, @ndmitchell, @connernilsen, @xaskii, @melvinhe, @migeed-z, @TheRustyPickle, @arnav-jain1, @InSyncWithFoo, @rubmary, @arthaud, @samwgoldman, @grievejia, @danielocfb-test, @MaggieMoss, @DavidTolnay, @JunHao, @darricklaidin, @kinto0
Nothing published for this version
Nothing published for this version
Pyrefly 0.22.0 bundles 216 commits from 23 contributors. This release includes significant improvements in type checking and performance enhancements.
Status : ALPHA
Release date: 30 Jun 2025
Pyrefly 0.22.0 bundles 216 commits from 23 contributors. This release includes significant improvements in type checking and performance enhancements.
| Area | What’s new |
|---|---|
| Type Checking | Implemented support for functools.total_ordering, allowing automatic generation of rich comparison methods. |
| IDE / LSP | Added support for textDocument/rename and textDocument/prepareRename in LSP. |
| Configuration | Introduced CLI flag for --conda-environment to manage Python environments more effectively. |
NamedTuple field ordering and TypedDict method synthesis.type[tuple] can now be used as a tuple constructorstr, not just literals.pip install --upgrade pyrefly==0.22.0
@Adist319, @adsi7698, @bigfootjon, @connernilsen, @CookieComputing, @dluo, @facebook-github-bot, @fangyi-zhou, @grievejia, @iwakitakuma33, @kinto0, @krathul, @melvinhe, @migeed-z, @ndmitchell, @pt2302, @rchen152, @SamChou19815, @stroxler, @vagabond-0, @xaskii, @yangdanny97, @zsol
https://github.com/facebook/pyrefly/releases
Full Changelog: https://github.com/facebook/pyrefly/compare/0.21.0...0.22.0
Status : ALPHA *Release date: 23 June 2025*
Status : ALPHA
Release date: 23 June 2025
Pyrefly 0.21.0 delivers 176 commits from 20 contributors. We now support a number of highly requested features such as Semantic Highlighting, Signature Help, Document Highlights and Auto Import Completions! Follow along for more LSP functionality #344 ahead of our V1 release.
| Area | What’s new |
|---|---|
| IDE / LSP (Issue #344) | • Richer semantic highlighting – method calls, property accesses, and the expressions nested in them now get distinct token types, so editors like VS Code underline exactly what you expect (#344).<br>• Added the defaultLibrary semantic-token modifier for symbols originating from builtins, typing, or typing_extensions; makes built-ins stand out in both dark/light themes. |
| Diagnostics | • Detailed override errors – incompatibilities between a subclass attribute and its parent now explain why they don’t match (“read-write vs read-only”, “int vs str”, etc.) on a second indented line. |
| Type-system smarts | • InitVar fields in @dataclass definitions are no longer treated as instance attributes, eliminating false “missing attribute” errors (PR [#437]). <br> • Full support for Variance Inference in Generic Classes with PEP 695 |
| Performance | • A pathological Callable | … union test that once blew up exponentially now checks in linear time. |
defaultLibrary modifier.pip install --upgrade pyrefly==0.21.0
@yangdanny97 @Adist319 @grievejia @connernilsen @migeed-z @ndmitchell @xl4624 @stroxler @rchen152 @TheRustyPickle @dluo @kinto0 @pt2302 @SamChou19815 @ducdetronquito @xaskii @Alex-Aron @hugovk @grantlouisherman @rubmary
Nothing published for this version
Nothing published for this version
Status : ALPHA *Release date: 16 June 2025*
Status : ALPHA
Release date: 16 June 2025
Pyrefly 0.20.0 represents 165 commits from 21 contributors and focuses on stability, friendlier diagnostics, and CLI quality-of-life.
Special thanks to @TheRustyPickle, @ducdetronquito, @pt2302, @akmalsoliev and every reviewer, tester and bug-reporter who helped make this release!
| Area | What’s new |
|---|---|
| Diagnostics & error messages | •We now print a snippet of source code in each message, highlighting the error location. You can control error message verbosity with the new --output-format=min-text and --output-format=full-text options.<br> •Add tests to keep Error Kinds in sync with documentation, in addition to reclassifying Error Kinds previously reported as Unknown (#477).<br>• Import errors are now shown on separate lines with source hints, thanks to the new BindingsBuilder::error_multiline helper (commit 2bba00f).<br>•TypeVar reveal output is shorter and clearer – no more variance=PInvariant noise (#225). |
| Editor support | •Basic support for Semantic Highlighting, a highly requested feature (#218). More improvements to come in future releases. |
| Configuration / CLI | • New flags --replace-imports-with-any and --ignore-missing-source let you suppress noisy import errors without editing config files (#480 → closes #460 & #462). |
| Type-system smarts | • Conflicting Required/NotRequired qualifiers in a single TypedDict field now surface an explicit error (#447→ fixes #414). |
| Project workflow | • pyrefly init edits an existing pyproject.toml in-place instead of appending duplicate [tool.pyrefly] sections (#336). |
--python-version 3.9 (#56).pyrefly check --help or grep error kinds.TypedDict qualifier rule (#447) may surface new errors where both Required and NotRequired were previously accepted.pip install --upgrade pyrefly==0.20.0
🖊️ Contributors in this release
@rchen152, @grievejia, @stroxler, @ajaymiranda, @connernilsen, @pt2302, @kinto0, @yangdanny97, @ndmitchell, @migeed-z, @hugovk, @dtolnay, @Alex-Aron, @Adist319, @zachmullen, @grantlouisherman, @rubmary, @dluo, @MaggieMoss, @kinto0, @SamChou19815
Nothing published for this version
Nothing published for this version
Pyrefly 0.19.0 packs a week’s worth of fixes and quality‑of‑life improvements into 128 commits from 19 contributors, touching 153 files.
Status : ALPHA
Release date: 9 June 2025
Pyrefly 0.19.0 packs a week’s worth of fixes and quality‑of‑life improvements into 128 commits from 19 contributors, touching 153 files.
Thank you @ajaymiranda @Adist319 @Alex-Aron @zachmullen for your contributions!
| Area | What’s new |
|---|---|
| Editor support | • Neovim integration — first‑class LSP support plus a helper command to install/update the server (#227).<br>• Neovim now respects pyrefly.toml and remote config overrides (#442). |
| Configuration UX | • Eliminates misleading “Extra keys” parse errors in pyrefly.toml (#441).<br>• Added validation that a TypedDict field cannot be both Required and NotRequired (#414). |
| Diagnostics | • reveal_type messages are now INFO‑level instead of errors, so they no longer fail CI runs when you’re just inspecting types (#304).<br>• isinstance() checks involving Union[...] are now inferred correctly (#426). |
| Type‑system smarts | • Better handling of Self generics in chained method calls (#152).<br>• Fixed constrained TypeVar attribute access (#318).<br>• Fixed failure when calling methods on a plain TypeVar (#150). |
| Stub & third‑party typing | • Works with inline stub files that live beside their implementation (#419).<br>• Correctly recognises pandas-stubs generic aliases such as Index without type arguments (#427). |
TypedDict qualifier rule (#414) will surface errors in code that previously passed silently.reveal_type raising an error exit status, update scripts to look for an info‑level diagnostic instead (#304).pip install --upgrade pyrefly==0.19.0
@Adist319, @Alex-Aron, @connernilsen, @yangdanny97, @dluo , @dtolnay, @hugovk, @grantlouisherman, @grievejia, @kinto0, @MaggieMoss, @ndmitchell, @rchen152, @rubmary, @SamChou19815, @stroxler, @migeed-z
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
One column per month.