r/Python • u/BeamMeUpBiscotti • 28d ago
News Microsoft partners w/ Meta to bring Pyrefly support to Pylance in VS Code
Link to blog: https://devblogs.microsoft.com/python/announcing-tsp/
TLDR:
Pylance (Microsoft's Python extension for VS Code) now officially supports using Meta's Pyrefly to power its analysis.
To enable this, Microsoft developed an extension to the language server protocol (LSP) called the type server protocol (TSP), a new standard that separates wider set of language server features from the type checker/compiler powering some of them.
111
Upvotes
5
u/Forward-War-8805 27d ago
Hope Ty gets the same treatment when 1.0 releases
31
u/2AetherSpindle 28d ago
More competition in Python tooling is always a good thing. Hopefully this makes type checking faster without adding more setup headaches
14
u/me_myself_ai 28d ago
Wait… what?? The actual feature isn’t relevant to me, but TSPs?? Hell yeah, gotta check that out as soon as possible.
9
u/MapNo2659 27d ago
This is pretty exciting news! Integrating Pyrefly with Pylance could really enhance the analysis capabilities in VS Code. I'm curious about how the new TSP will impact performance compared to the existing LSP. Has anyone tried it out yet and noticed any significant differences?
3
u/preetam960 26d ago
To try it, set Python › Analysis: Diagnostics Source to "Pylance + Pyrefly". It needs Pylance 2026.4.1 or newer and Pyrefly 0.60.0 or newer. Pylance uses the pyrefly in your venv if there is one and downloads it otherwise. Python › Analysis: Pyrefly Version pins a version or points at a local binary, handy if CI runs a specific release.
1
u/RedEyed__ 25d ago
This is nice!
Pyrefly cli is awesome, but extension is not
1
u/Muchy_Tangerine 3d ago
This could make competitive, which interface is better and user workability