uranusjr commented on PR #31486:
URL: https://github.com/apache/airflow/pull/31486#issuecomment-1560372245

   Hmm, db init is failing with
   
   ```
   sqlalchemy.exc.IntegrityError: (psycopg2.errors.NotNullViolation) null value 
in column "created_at" violates not-null constraint
   DETAIL:  Failing row contains (1, {{ ti.dag_id }}/{{ ti.task_id }}/{{ ts 
}}/{{ try_number }}.log, {dag_id}-{task_id}-{execution_date}-{try_number}, 
null).
   ```
   
   But `LogTemplate.created_at` has `default=timezone.utcnow`, which should 
kick in to add a default value on the client side to the insert query, 
[according to 
documentation](https://docs.sqlalchemy.org/en/20/core/defaults.html). This has 
been working fine in 1.x and I don’t see any notes indicating anything changed 
in 2.0. Something is off.


-- 
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]

Reply via email to