ephraimbuddy opened a new pull request, #27942:
URL: https://github.com/apache/airflow/pull/27942

   
   This reverts commit 9409293514cef574179a5320ed3ed50881064423.
   
   @tirkarthi we can't view grid view of a dag if the Param type is boolean
   
   ```python
   int1 = randint(20, 200)
   bool1 = []
   bools = bool1.append(True) if int1 % 2 == 0 else bool1.append(False)
   
   @task
   def fail_if_invalid(val):
           print(val)
           assert type(val[0]) == bool
   
   
   @dag(
       start_date=datetime(1970, 1, 1),
       schedule_interval=timedelta(days=365 * 30),
       params={"val": Param(False, type="boolean")},
       doc_md=docs,
       tags=["core", "taskflow-api", "dag-params"],
   )
   def bool_taskflow_test(bool_val):
   
       # val is a DagParam object
       # print(val)  # <airflow.models.param.DagParam object at 0x103360b50>
   
       # the task dereferences it
       fail_if_invalid(bool_val)
   
   
   the_dag = bool_taskflow_test(bool1)
   ```


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