3 ms·
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
by insane_dreamer 2y ago
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.
- arthur-st 2y agoCheck if your configuration allows pyright to use other files in the workspace.
- olejorgenb 2y agoIf 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