Set explicit primaryjoin for AI generation run -> items relationship
This commit is contained in:
@@ -68,6 +68,7 @@ class AIGenerationRun(Base):
|
|||||||
generated_items: Mapped[list["Item"]] = relationship(
|
generated_items: Mapped[list["Item"]] = relationship(
|
||||||
"Item",
|
"Item",
|
||||||
back_populates="generation_run",
|
back_populates="generation_run",
|
||||||
|
primaryjoin="AIGenerationRun.id == Item.generation_run_id",
|
||||||
foreign_keys="Item.generation_run_id",
|
foreign_keys="Item.generation_run_id",
|
||||||
lazy="selectin",
|
lazy="selectin",
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user