uranusjr commented on code in PR #34120:
URL: https://github.com/apache/airflow/pull/34120#discussion_r1316776989
##########
airflow/models/dagrun.py:
##########
@@ -1411,7 +1411,12 @@ class DagRunNote(Base):
__tablename__ = "dag_run_note"
user_id = Column(Integer, nullable=True)
- dag_run_id = Column(Integer, primary_key=True, nullable=False)
+ dag_run_id = Column(
+ Integer,
+ primary_key=True,
+ nullable=False,
+ foreign_key=ForeignKey("ab_user.id", name="dag_run_note_user_fkey"),
+ )
Review Comment:
Shouldn’t the fk be on the `user_id` column instead?
##########
airflow/models/dagrun.py:
##########
@@ -1411,7 +1411,12 @@ class DagRunNote(Base):
__tablename__ = "dag_run_note"
user_id = Column(Integer, nullable=True)
- dag_run_id = Column(Integer, primary_key=True, nullable=False)
+ dag_run_id = Column(
+ Integer,
+ primary_key=True,
+ nullable=False,
+ foreign_key=ForeignKey("ab_user.id", name="dag_run_note_user_fkey"),
+ )
Review Comment:
Shouldn’t the fk be on the `user_id` column instead?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]