Repository navigation
Conversation
A model declaring a concrete relation next to a ForwardRef relation failed at class creation with PydanticUndefinedAnnotation: the reverse field on the concrete target embeds a copy of the model whose forward ref is unresolved. Schema rebuilds now defer instead of raising, and update_forward_refs() rebuilds the related and through models left incomplete.
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Merging this PR will degrade performance by 18.9%2 warnings
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing |
A model declaring a concrete relation next to a
ForwardRefone (e.g.ForeignKey(Author)andForeignKey(ForwardRef("Book"))) failed at class creation withPydanticUndefinedAnnotation: the reverse field onAuthorembeds a copy of the model whoseBookref is still unresolved. Schema rebuilds triggered while refs are pending now defer instead of raising, andupdate_forward_refs()rebuilds the related and through models left incomplete. An undefined ref still raisesNameErrorfromupdate_forward_refs().