🔍💥 Welcome to the #Python #type checker showdown nobody asked for! Watch as the nerds at #Pyrefly unleash a flood of #buzzwords, promising type-checking utopia while drowning developers in a sea of overly-complicated syntax. 🤯 Spoiler: nobody cares about your #type #completeness score, Pyrefly. 🙄
https://pyrefly.org/blog/typing-conformance-comparison/ #Checking #Developer #Struggles #HackerNews #ngated
Python Type Checker Comparison: Typing Spec Conformance | Pyrefly

Learn what it means to conform to the Python typing spec, why it matters, and the conformance status of each type checker including Pyrefly, Ty, Pyright and Mypy.

🚀 Pyrefly: the trailblazing type checker that'll make your #IDE shine like a supernova! If you're eagerly waiting to compare empty containers while flying through type hints at light speed, #Pyrefly has got you covered. 💫 Who knew #debugging #Python could be this thrilling? 🙄
https://pyrefly.org/blog/container-inference-comparison/ #TypeChecker #Innovation #HackerNews #ngated
Python Type Checker Comparison: Empty Container Inference | Pyrefly

Learn how different type checkers handle empty containers in Python, including Pyrefly, Ty, Pyright and Mypy.

Pyrefly giới thiệu 4 mẫu thu hẹp loại dữ liệu giúp kiểm tra kiểu trong Python trực quan hơn qua: 1. hasattr/getattr, 2. tagged unions, 3. kiểm tra độ dài tuple, 4. lưu điều kiện trong biến. Pyrefly hiện là trình kiểm tra kiểu duy nhất hỗ trợ đầy đủ các mẫu này. Tìm hiểu thêm tại trang chủ hoặc GitHub. #Python #TypeChecking #Pyrefly #LậpTrình #KiểmTraKiểu

https://www.reddit.com/r/programming/comments/1qolknv/4_pyrefly_type_narrowing_patterns_that_make/

With high-performance #Python type checkers like #Pyright, #Pyrefly, and #ty now available, what's the value proposition of #Mypy? Is it the reference implementation? Or does Mypy still have the most features? I'm not trying to knock Mypy, I'm genuinely asking because I don't know.

Let's say you want to do good type-checking for the #Python project you're working on. You pick a tool, maybe you use it as an #LSP also (so your editor can show you errors, too). As an example, I'm using #Ty at the moment. There's three places this might be installed: globally (e.g., `brew install ty`), as a dev-only dependency inside your project (e.g., `uv add --dev ty`), or -- and this one might surprise you -- it might only be used and installed by `pre-commit`, which builds a separate environment for each needed tool (which is great for instance where I use `codespell` as a `pre-commit` check, which seems to need some higher version of Python than my actual project).

Where should you install it?

If you're the only one on your team running it, globally is fine. If more than just you, then absolutely as a dev-only dependency inside your project ... and **maybe** globally as well.

The only real problem is updates. If you use a reasonable global install scheme, updates will be easy. They're less easy inside your project or in `pre-commit`. And you might care one way or the other! I **don't** want updates! I **do** want updates!

As for Python type-checking, `ty` seems good so far, but not enough experience with it yet. `basedpyright`, `pyrefly`, and `ruff` all good. These four are my favorites.

#BasedPyright #Pyrefly #Ruff #PreCommit #CodeSpell #Homebrew

Both #ty and #pyrefly reached beta recently. Pyrefly team have announced they're targeting V1 in early 2026. Given that the Pyrefly team works closely with the Django users at Instagram, I'm expecting good things from them. Early signs are good because of their experimental Django support similar to the mypy plugin.

#ty are targetting dataclass transform similar to Pyright. I doubt that'll ever be good enough.

Exciting times in Python type checking.

Well … I get symbol renaming if I use #BasedPyright as my #LSP

#Pyrefly #AdventOfCode

It seems like my #Pyrefly problem isn’t related to my #AdventOfCode project. Before pyrefly, I could rename a symbol throughout the project. With pyrefly, I can’t. More investigation needed.

Working on #AdventOfCode. My plan was to solve each day in both #Python and #RustLang. I thought I would be further by now. Yes, my Python answer to day 1 solves both parts, but I'm trying to be exemplary: good names, docstrings, comments-where-needed, tests, project structure, all the things.

For some reason, #HelixEditor keeps complaining about the #LSP (using both #Pyrefly and #Ruff, as usual). I'm concerned I haven't set things up right somehow, but I don't yet see where I've gone wrong.

Once this is working, further days will be easy. At least ... I hope!

Rustで書かれた高速Python型チェッカー「Pyrefly」の紹介 | gihyo.jp

今月の「Python Monthly Topics」は、型チェッカー「Pyrefly」を紹介します。

gihyo.jp