Module ImportFrom alias ImportFrom alias alias alias ImportFrom alias ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam defaults Str vararg kwarg body Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr keyword NameLoad NameLoad NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Return Call NameLoad keyword AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad Str vararg kwarg body Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad NameLoad NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Return Call NameLoad keyword AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam defaults Str Num Str vararg kwarg body Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad NameLoad NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Return Call NameLoad keyword AttributeLoad NameLoad attr decorator_list decorator_list
N/A airflow.contrib.hooks.bigquery_hook BigQueryHook airflow.operators CheckOperator ValueCheckOperator IntervalCheckOperator airflow.utils.decorators apply_defaults BigQueryCheckOperator N/A CheckOperator N/A N/A 
    Performs checks against Presto. The ``BigQueryCheckOperator`` expects
    a sql query that will return a single row. Each value on that
    first row is evaluated using python ``bool`` casting. If any of the
    values return ``False`` the check is failed and errors out.

    Note that Python bool casting evals the following as ``False``:
    * False
    * 0
    * Empty string (``""``)
    * Empty list (``[]``)
    * Empty dictionary or set (``{}``)

    Given a query like ``SELECT COUNT(*) FROM foo``, it will fail only if
    the count ``== 0``. You can craft much more complex query that could,
    for instance, check that the table has the same number of rows as
    the source table upstream, or that the count of today's partition is
    greater than yesterday's partition, or that a set of metrics are less
    than 3 standard deviation for the 7 day average.

    This operator can be used as a data quality check in your pipeline, and
    depending on where you put it in your DAG, you have the choice to
    stop the critical path, preventing from
    publishing dubious data, or on the side and receive email alterts
    without stopping the progress of the DAG.

    :param sql: the sql to be executed
    :type sql: string
    :param bigquery_conn_id: reference to the BigQuery database
    :type presto_conn_id: string
     __init__ N/A N/A self sql bigquery_conn_id N/A bigquery_default args kwargs N/A N/A N/A N/A N/A super BigQueryCheckOperator self __init__ sql sql args kwargs N/A N/A self bigquery_conn_id bigquery_conn_id N/A N/A self sql sql N/A apply_defaults get_db_hook N/A N/A self N/A N/A N/A N/A BigQueryHook bigquery_conn_id N/A self bigquery_conn_id N/A N/A BigQueryValueCheckOperator N/A ValueCheckOperator N/A N/A 
    Performs a simple value check using sql code.

    :param sql: the sql to be executed
    :type sql: string
     __init__ N/A N/A self sql pass_value tolerance bigquery_conn_id N/A None bigquery_default args kwargs N/A N/A N/A N/A N/A super BigQueryValueCheckOperator self __init__ sql sql pass_value pass_value tolerance tolerance args kwargs N/A N/A self bigquery_conn_id bigquery_conn_id N/A apply_defaults get_db_hook N/A N/A self N/A N/A N/A N/A BigQueryHook bigquery_conn_id N/A self bigquery_conn_id N/A N/A BigQueryIntervalCheckOperator N/A IntervalCheckOperator N/A N/A 
    Checks that the values of metrics given as SQL expressions are within
    a certain tolerance of the ones from days_back before.

    This method constructs a query like so:

    SELECT {metrics_threshold_dict_key} FROM {table}
        WHERE {date_filter_column}=<date>

    :param table: the table name
    :type table: str
    :param days_back: number of days between ds and the ds we want to check
        against. Defaults to 7 days
    :type days_back: int
    :param metrics_threshold: a dictionary of ratios indexed by metrics, for
        example 'COUNT(*)': 1.5 would require a 50 percent or less difference
        between the current day, and the prior days_back.
    :type metrics_threshold: dict
     __init__ N/A N/A self table metrics_thresholds date_filter_column days_back bigquery_conn_id N/A ds -7 bigquery_default args kwargs N/A N/A N/A N/A N/A super BigQueryIntervalCheckOperator self __init__ table table metrics_thresholds metrics_thresholds date_filter_column date_filter_column days_back days_back args kwargs N/A N/A self bigquery_conn_id bigquery_conn_id N/A apply_defaults get_db_hook N/A N/A self N/A N/A N/A N/A BigQueryHook bigquery_conn_id N/A self bigquery_conn_id N/A N/A