pyrefly
A fast type checker and language server for Python
Discover how Pyrefly's unique type solving engine, built in Rust, provides faster and more consistent Python type checking than other tools. See its groundbreaking performance.
How Pyrefly Handles Attribute Access and Property TypesLearn how Pyrefly handles attribute access and property types using its three phase pipeline: MRO resolution, getattr fallback, and descriptor protocol semantics for accurate type checking.
How to Use pyrefly init to Migrate from Mypy or Pyright ConfigurationEasily migrate Mypy or Pyright configurations to Pyrefly using the pyrefly init command. Automatically convert include paths and settings to pyrefly.toml or pyproject.toml.
How to Use pyrefly suppress to Migrate Existing Errors When UpgradingLearn how to use pyrefly suppress to migrate existing errors during Pyrefly upgrades. Freeze diagnostics, upgrade seamlessly, and clean up code with this powerful tool.
How to Use pyrefly infer to Generate Python Type AnnotationsLearn how to use pyrefly infer to automatically add type annotations to your Python code. This powerful tool analyzes your code and inserts type hints directly into your source files.
How Pyrefly Handles Type Aliases and Recursive ResolutionLearn how Pyrefly handles type aliases and recursive resolution with its two-phase architecture. Discover how it separates binding from solving for efficient type checking.
How Pyrefly Implements Callable Overload ResolutionLearn how Pyrefly implements callable overload resolution by storing signatures and matching them to PEP 484 rules to prevent type errors.
How Pyrefly Handles Import Resolution and Module FindingDiscover how Pyrefly handles import resolution and module finding with its hierarchical search algorithm. Learn about directory caching, stub package handling, and legacy namespace support.
How Pyrefly's Binding System Represents Definitions, Uses, and Phi FunctionsDiscover how Pyrefly's binding system represents definitions uses and phi functions using Key and Binding payloads for precise code analysis and type solving.
How Pyrefly Handles Variance Inference for Generic Classes: A Deep Dive into the AlgorithmPyrefly expertly handles variance inference for generic classes with a 3-phase constraint solver. Learn how it analyzes hierarchies, methods, and fields to determine type variable variance.
How Pyrefly Performs Type Inference for Empty Containers: Placeholder Variables and Lazy UnificationDiscover how Pyrefly handles type inference for empty containers using placeholder variables and lazy unification. Learn how it defers type resolution until containers are used.
How Pyrefly Handles Jaxtyping Tensor Shape Annotations: A Deep Dive into the Type SystemDiscover how Pyrefly handles Jaxtyping tensor shape annotations by parsing wrapper classes, tokenizing shapes, and converting to its internal TensorType. Learn about its syntax tracking.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →