seanghaeli commented on code in PR #77465:
URL: https://github.com/apache/airflow/pull/77465#discussion_r4739618075
##########
airflow-core/src/airflow/models/asset.py:
##########
@@ -144,6 +145,7 @@ class AssetWatcherModel(Base):
)
asset_id: Mapped[int] = mapped_column(Integer, primary_key=True,
nullable=False)
trigger_id: Mapped[int] = mapped_column(Integer, primary_key=True,
nullable=False)
+ is_paused: Mapped[bool] = mapped_column(Boolean, default=False,
nullable=False)
Review Comment:
nit: the migration gives `is_paused` a `server_default` of false but the
model doesn't, so a fresh install (built from the models) ends up with no
default while an upgraded DB has one. An insert that leaves out `is_paused`
fails on a fresh DB and works on an upgraded one (tried both in Breeze).
```suggestion
is_paused: Mapped[bool] = mapped_column(Boolean, default=False,
nullable=False, server_default=sa.false())
```
--
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]