airflow-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Allison Wang (JIRA)" <>
Subject [jira] [Created] (AIRFLOW-1485) Get configuration throws exceptions when key does not exist
Date Thu, 03 Aug 2017 20:44:00 GMT
Allison Wang created AIRFLOW-1485:

             Summary: Get configuration throws exceptions when key does not exist
                 Key: AIRFLOW-1485
             Project: Apache Airflow
          Issue Type: Bug
            Reporter: Allison Wang

Airflow configuration get method throws exceptions when the key is not defined in airflow.cfg.
This behavior makes adding new, optional configuration difficult given people already have
their own airflow.cfg. We should probably have another method to return an empty string instead
of throwing exceptions when there is no such key in airflow config. 
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/flask/", line 1817, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/", line 1477, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python2.7/dist-packages/flask/", line 1381, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python2.7/dist-packages/flask/", line 1475, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/", line 1461, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/local/lib/python2.7/dist-packages/flask_admin/", line 68, in inner
    return self._run_view(f, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/flask_admin/", line 367, in _run_view
    return fn(self, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/", line 755, in decorated_view
    return func(*args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/airflow/www/", line 125, in wrapper
    return f(*args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/airflow/www/", line 873, in log
    if conf.get('core', 'logging_backend_url'):
  File "/usr/local/lib/python2.7/dist-packages/airflow/", line 802, in get
    return conf.get(section, key, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/airflow/", line 615, in get
    "in config".format(**locals()))
AirflowConfigException: section/key [core/logging_backend_url] not found in config

This message was sent by Atlassian JIRA

View raw message