[ 
https://issues.apache.org/jira/browse/AIRFLOW-436?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Sumit Maheshwari resolved AIRFLOW-436.
--------------------------------------
    Resolution: Workaround

> Incorrect templating when used with .format
> -------------------------------------------
>
>                 Key: AIRFLOW-436
>                 URL: https://issues.apache.org/jira/browse/AIRFLOW-436
>             Project: Apache Airflow
>          Issue Type: Bug
>            Reporter: Sumit Maheshwari
>
> Found that when {{.format}} is used in a templatable field, it produces weird 
> results. For example:
> {code:none}
> t3 = BashOperator(
>     task_id='wget',
>     bash_command="wget {0}/{{ ds }}".format('google.com'),
>     dag=dag)
> {code}
> produces following result:
> {code:none}
> {bash_operator.py:79} INFO - Running command: wget google.com/{ ds }
> {code}
> But if we change {{bash_command}} to following, it works as expected:
> {code:none}
> bash_command="wget %s/{{ ds }}"%('google.com')
> {code}
> {code:none}
> {bash_operator.py:79} INFO - Running command: wget google.com/2016-08-05
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to