title: can't see log from python function execute from BashOperator - Airflow
body: <p>I'm using apache airflow with <code>BashOperator</code>. 
  Each <code>BashOperator</code> execute a python script.
  For example:</p>
  
  <pre><code>from airflow.models import DAG
  from airflow.operators.bash_operator import BashOperator
  with DAG(dag_id='dag_example', default_args=None,
               schedule_interval='0 2 */2 * *',
               catchup=False) as dag:
  
       run_task= BashOperator(
              task_id='simple_task',
              bash_command='python task.py',
              dag=dag)
  </code></pre>
  
  <p>Where <code>task.py</code> is:</p>
  
  <pre><code>import logging
  
  def log_fun():
      logging.info('Log something')
  
  if __name__=='__main__':
       log_fun()
  </code></pre>
  
  <p>I can't figure out why log doesn't appear in Airflow logs.
  I checked <code>airflow.cfg</code> and logging_level is correctly set to INFO.</p>