Shrividya commented on code in PR #64129:
URL: https://github.com/apache/airflow/pull/64129#discussion_r2978857235
##########
airflow-core/docs/core-concepts/dag-run.rst:
##########
@@ -271,7 +271,8 @@ Example of a parameterized Dag:
parameterized_task = BashOperator(
task_id="parameterized_task",
- bash_command="echo value: {{ dag_run.conf['conf1'] }}",
+ bash_command="echo \"here is the message: '$message'\"",
+ env={"message": '{{ dag_run.conf["message"] if dag_run else "" }}'},
Review Comment:
nice catch!
nit: better to keep `env={"message": "{{ dag_run.conf.get('message', 'no
message provided') }}"} ` to pass the value as an environment variable, just to
keep the bash_command clean.
--
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]