You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "sunank200 (via GitHub)" <gi...@apache.org> on 2023/06/13 12:07:06 UTC

[GitHub] [airflow] sunank200 commented on a diff in pull request #31293: openlineage, bigquery: add openlineage method support for BigQueryExecuteQueryOperator

sunank200 commented on code in PR #31293:
URL: https://github.com/apache/airflow/pull/31293#discussion_r1228012710


##########
airflow/providers/google/cloud/operators/bigquery.py:
##########
@@ -1138,7 +1139,7 @@ def execute(self, context: Context):
                 impersonation_chain=self.impersonation_chain,
             )
         if isinstance(self.sql, str):
-            job_id: str | list[str] = self.hook.run_query(
+            self.job_id = self.hook.run_query(

Review Comment:
   What is the benefit of making this a class variable? Is it to use it for open lineage? Is it not available in xcom?



##########
airflow/providers/openlineage/extractors/base.py:
##########
@@ -84,6 +84,12 @@ def get_operator_classnames(cls) -> list[str]:
     def extract(self) -> OperatorLineage | None:
         try:
             return self._get_openlineage_facets(self.operator.get_openlineage_facets_on_start)  # type: ignore
+        except ImportError:
+            self.log.error(
+                "OpenLineage provider method failed to import OpenLineage integration. "

Review Comment:
   Should we not ask the user to install open lineage here?



-- 
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.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org