molcay commented on code in PR #39165:
URL: https://github.com/apache/airflow/pull/39165#discussion_r1590616088


##########
airflow/api/common/trigger_dag.py:
##########
@@ -104,6 +107,7 @@ def _trigger_dag(
 
 def trigger_dag(
     dag_id: str,
+    triggered_by: DagRunTriggeredByType,

Review Comment:
   OK, it makes sense. Do you think that it is wise to use `*` as a parameter 
before the `triggered_by` parameter to force to use named arguments (as below)? 
   ```python
   def trigger_dag(
       dag_id: str,
       *,  # <- new line
       triggered_by: DagRunTriggeredByType,
   ```
   
   I think the other option is setting to `None` as the default value and 
checking the value is `None` in the function body.  This option will definitely 
look ugly.
   
   WDYT? @uranusjr 



-- 
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: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to