Repository navigation
fix Add support for Django reverse relationships for cross module #2071 - #5130
asukaminato0721 wants to merge 3 commits into
Conversation
|
This pull request has been imported. If you are a Meta employee, you can view this in D123799553. (Because this pull request was imported automatically, there will not be any future comments.) |
|
todo: this will need manually add configure, is it possible to do some cold start? |
This comment has been minimized.
This comment has been minimized.
|
Not familiar with how the Rust code works, but will this support globs ( |
This comment has been minimized.
This comment has been minimized.
|
According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅ |
|
@asukaminato0721 thanks for taking another stab at this. Sorry for never getting around to posting design ideas as I promised to on your last PR. This direction looks promising to me, but AI review turned up a couple potentially blocking correctness issues (1, 2) and a couple more minor issues. I haven't vetted these carefully, so please feel free to push back on anything the AI got wrong:
@samwgoldman I'd love to get your thoughts on this change, since you're much more familiar with the state machinery. |
rchen152
left a comment
There was a problem hiding this comment.
(Forgot to submit a review XD)
Reverse relationship discovery needs an explicit list of model modules to support lazy loading. Add the configuration contract, validation, and reference documentation for that list.
Load explicitly configured model modules when solving reverse relationships and record their dependencies. This supports cross-module relations with lazy module loading and invalidation, without scanning all loaded modules.
|
According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅ |
Summary
Fixes #2071
By let user write these models down in configure.
Test Plan
add test