Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I've found pyright to be limited in its ability to infer types, especially compared to Pycharm, which can resolve class inherence across multiple modules quite well. I noticed this when trying to use Zed instead of Pycharm.


If you actually type your code [1], pyright is miles ahead pycharm in every case I've seen. For partially/incorrectly typed code pycharm is often better in practice because it relies on heuristics. (tbf. Some libraries lack or have bad stubs, which can be annoying using pyright (eg. Pandas)).

[1] You don't have to typehint everything for this to work. Pyright infers return types just fine for instance


Check if your configuration allows pyright to use other files in the workspace.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: