You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "Bryan Yang (JIRA)" <ji...@apache.org> on 2019/04/09 02:55:00 UTC

[jira] [Created] (AIRFLOW-4265) Lineage backend did not work normally

Bryan Yang created AIRFLOW-4265:
-----------------------------------

             Summary: Lineage backend did not work normally
                 Key: AIRFLOW-4265
                 URL: https://issues.apache.org/jira/browse/AIRFLOW-4265
             Project: Apache Airflow
          Issue Type: Bug
            Reporter: Bryan Yang
            Assignee: Bryan Yang


1. Lineage backend comes from {{import_string}} function, and {{import_string}} will try to seperate module_path and class_name by dot.
{quote}def import_string(dotted_path):
 """
 Import a dotted module path and return the attribute/class designated by the
 last name in the path. Raise ImportError if the import failed.
 """
 try:
 module_path, class_name = dotted_path.rsplit('.', 1)
 except ValueError:
 raise ImportError("{} doesn't look like a module path".format(dotted_path))

module = import_module(module_path)
{quote}
But in the current document: {{backend = airflow.lineage.backend.atlas}} which is just a module path without class name \{{AtlasBackend}}.

2. Continuously, this function will return a module or class instead of an instance. So that when {{apply_lineage}} want to call {{backend.send_lineage}}, it will fail.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)