jscheffl commented on issue #46858:
URL: https://github.com/apache/airflow/issues/46858#issuecomment-2666953817

   I can confirm testing with Airflow 2.10.5 that a new bug in the trigger form 
was introduced. Using the DAG...
   ```
   import pendulum
   
   from airflow.models.dag import DAG
   from airflow.models.param import Param
   from airflow.operators.python import PythonOperator
   
   with DAG(
       "bug_46858",
       schedule=None,
       start_date=pendulum.datetime(2021, 1, 1, tz="UTC"),
       params={
           "some_object": Param(
               {},
               type="object",
               title="JSON entry field",
           ),
       },
   ) as dag:
       def some_code():
           print("test")
       some_task = PythonOperator(
           task_id="some_task",
           python_callable=some_code,
       )
   ```
   ...the JSON element is NOT correctly initialized and as a follow-up issue 
the submission fails in JavaScript. This was working with Airflow 2.10.4.
   
   As a workaround - until a fix is landing - the bug is only happening if NO 
default value is provided in the form. If you provide a default with...
   ```
       params={
           "some_object": Param(
               {"key": "value"},
               type="object",
               title="JSON entry field",
           ),
       },
   
   ```
   ...then the form is working.
   
   I assume it is related to https://github.com/apache/airflow/pull/45315 which 
was the only change since Airflow 2.10.4.


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