This is an automated email from the ASF dual-hosted git repository.

kaxilnaik pushed a commit to branch v3-0-test
in repository https://gitbox.apache.org/repos/asf/airflow.git

commit 416fdb6046af0f26493135ea74cc596359e189c4
Author: Daniel Standish <[email protected]>
AuthorDate: Tue Apr 22 13:30:49 2025 -0700

    Null out the scheduler_interval field on downgrade (#49583)
    
    In 2.x, it was expected that this field was valid json -- e.g. `"0 0 * * 
*"`.
    
    In 3.x, the column is renamed and repurposed and not json.
    
    So if we downgrade it, we need to null it out.  It will get updated when 
dag is reserialized.
    
    If we *don't* do this, the scheduler crashes.
    
    (cherry picked from commit 1bad247c2ad0e86a1816ac09a65bb944bde40085)
---
 airflow-core/docs/img/airflow_erd.sha256                                | 2 +-
 .../versions/0030_3_0_0_rename_schedule_interval_to_timetable_.py       | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/airflow-core/docs/img/airflow_erd.sha256 
b/airflow-core/docs/img/airflow_erd.sha256
index 5ec0d8e84d1..fae49f1bfab 100644
--- a/airflow-core/docs/img/airflow_erd.sha256
+++ b/airflow-core/docs/img/airflow_erd.sha256
@@ -1 +1 @@
-2a3ce828be7c3800cb61de4c081fcf46f1f94e31ac732f831e65a8a9581b5bb0
\ No newline at end of file
+94023084fb9e30f248831a04f0bbabf5b7d90332b7edc013c7a5305340c4e1bf
\ No newline at end of file
diff --git 
a/airflow-core/src/airflow/migrations/versions/0030_3_0_0_rename_schedule_interval_to_timetable_.py
 
b/airflow-core/src/airflow/migrations/versions/0030_3_0_0_rename_schedule_interval_to_timetable_.py
index b4434a65f3f..16f78293310 100644
--- 
a/airflow-core/src/airflow/migrations/versions/0030_3_0_0_rename_schedule_interval_to_timetable_.py
+++ 
b/airflow-core/src/airflow/migrations/versions/0030_3_0_0_rename_schedule_interval_to_timetable_.py
@@ -58,3 +58,4 @@ def downgrade():
             type_=sa.Text,
             nullable=True,
         )
+    op.execute("UPDATE dag SET schedule_interval=NULL;")

Reply via email to