kaxil commented on a change in pull request #8176: Improve add_dag_code_table migration URL: https://github.com/apache/airflow/pull/8176#discussion_r404886314
########## File path: airflow/migrations/versions/952da73b5eff_add_dag_code_table.py ########## @@ -38,6 +37,18 @@ def upgrade(): + from sqlalchemy.ext.declarative import declarative_base + + Base = declarative_base() + + class SerializedDagModel(Base): + __tablename__ = 'serialized_dag' + + # There are other columns here, but these are the only ones we need for the SELECT/UPDATE we are doing + dag_id = sa.Column(sa.String(250), primary_key=True) + fileloc = sa.Column(sa.String(2000), nullable=False) + fileloc_hash = sa.Column(sa.BigInteger, nullable=False) Review comment: Ignore me. I see we use the model after changing COlumn type ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
