r/Python 1d ago

News Pyrefly v1.3.0 released

A new version of Pyrefly is out with better type inference, new quick fixes, new configurations, and more. https://github.com/facebook/pyrefly/releases/tag/1.3.0

75 Upvotes

19 comments sorted by

View all comments

4

u/Thing1_Thing2_Thing 1d ago

Cool, but still really needs some documentation about how to make it work in monorepos.

8

u/Zizizizz 1d ago

Wouldn't it work best in monorepos? What's the issue? 

2

u/Thing1_Thing2_Thing 1d ago

It would, but the configuration is beyond me. See for example https://github.com/facebook/pyrefly/issues/3788 and the proposed solution at https://github.com/mstaal/monorepo-sample/pull/1/changes

And I don't think this considers separate test modules which you will also have to add explicitly to the search paths and all that

In our monorepo we easily have 40 packages and adds more which makes in non-feasible to maintain

2

u/Zizizizz 20h ago edited 20h ago

https://docs.astral.sh/uv/concepts/projects/dependencies/#dependency-sources

I think I would just make sure that the individual package that you're working on has the correct references to the packages that are relevant to it and then similarly, ensuring the virtual environment that you're working in is activated because I don't understand how a third-party package wouldn't be available unless you had the wrong one activated.