You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by ka...@apache.org on 2020/08/14 19:07:33 UTC

[airflow] branch v1-10-test updated: Replace deprecated base classes used in bigquery_check_operator (#10272)

This is an automated email from the ASF dual-hosted git repository.

kaxilnaik pushed a commit to branch v1-10-test
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/v1-10-test by this push:
     new 5f4aed9  Replace deprecated base classes used in bigquery_check_operator (#10272)
5f4aed9 is described below

commit 5f4aed9e258ad3d805ec463ddeeb875eb704145c
Author: dewaldabrie <de...@gmail.com>
AuthorDate: Sat Aug 15 05:06:52 2020 +1000

    Replace deprecated base classes used in bigquery_check_operator (#10272)
    
    Co-authored-by: Dewald Abrie <de...@rentalcover.com>
---
 airflow/contrib/operators/bigquery_check_operator.py | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/airflow/contrib/operators/bigquery_check_operator.py b/airflow/contrib/operators/bigquery_check_operator.py
index 3559291..c34fd52 100644
--- a/airflow/contrib/operators/bigquery_check_operator.py
+++ b/airflow/contrib/operators/bigquery_check_operator.py
@@ -18,12 +18,12 @@
 # under the License.
 
 from airflow.contrib.hooks.bigquery_hook import BigQueryHook
-from airflow.operators.check_operator import \
-    CheckOperator, ValueCheckOperator, IntervalCheckOperator
+from airflow.operators.sql import \
+    SQLCheckOperator, SQLValueCheckOperator, SQLIntervalCheckOperator
 from airflow.utils.decorators import apply_defaults
 
 
-class BigQueryCheckOperator(CheckOperator):
+class BigQueryCheckOperator(SQLCheckOperator):
     """
     Performs checks against BigQuery. The ``BigQueryCheckOperator`` expects
     a sql query that will return a single row. Each value on that
@@ -79,7 +79,7 @@ class BigQueryCheckOperator(CheckOperator):
                             use_legacy_sql=self.use_legacy_sql)
 
 
-class BigQueryValueCheckOperator(ValueCheckOperator):
+class BigQueryValueCheckOperator(SQLValueCheckOperator):
     """
     Performs a simple value check using sql code.
 
@@ -111,7 +111,7 @@ class BigQueryValueCheckOperator(ValueCheckOperator):
                             use_legacy_sql=self.use_legacy_sql)
 
 
-class BigQueryIntervalCheckOperator(IntervalCheckOperator):
+class BigQueryIntervalCheckOperator(SQLIntervalCheckOperator):
     """
     Checks that the values of metrics given as SQL expressions are within
     a certain tolerance of the ones from days_back before.