ashb commented on a change in pull request #14146:
URL: https://github.com/apache/airflow/pull/14146#discussion_r572776319
##########
File path: airflow/lineage/__init__.py
##########
@@ -45,6 +48,20 @@ class Metadata:
data: Dict = attr.ib()
+def _get_backend() -> Optional[LineageBackend]:
+ _backend: Optional[LineageBackend] = None
+
+ try:
+ _backend_str = conf.get("lineage", "backend")
+ _backend = import_string(_backend_str) #
pylint:disable=protected-access
+ except ImportError as err:
+ log.debug("Cannot import %s due to %s", _backend_str, err) #
pylint:disable=protected-access
+ except AirflowConfigException:
+ log.debug("Could not find lineage backend key in config")
Review comment:
Lineage is an optional feature, and this is just restoring the deleted
code, so I don't think we need a default.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]