Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion providers/google/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ requires-python = ">=3.10"
# After you modify the dependencies, and rebuild your Breeze CI image with ``breeze ci-image build``
dependencies = [
"apache-airflow>=2.11.0",
"apache-airflow-providers-common-compat>=1.10.1",
"apache-airflow-providers-common-compat>=1.10.1", # use next version
"apache-airflow-providers-common-sql>=1.27.0",
"asgiref>=3.5.2",
"dill>=0.2.3",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@
# Make mypy happy by importing as aliases
import google.cloud.storage as storage

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowNotFoundException
from airflow.providers.common.compat.sdk import AirflowNotFoundException, conf
from airflow.providers.google.cloud.hooks.gcs import GCSHook, _parse_gcs_url
from airflow.providers.google.cloud.utils.credentials_provider import (
get_credentials_and_project_id,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,8 @@
from google.cloud.bigquery import DEFAULT_RETRY, CopyJob, ExtractJob, LoadJob, QueryJob, Row
from google.cloud.bigquery.table import RowIterator, Table, TableListItem, TableReference

from airflow.configuration import conf
from airflow.exceptions import AirflowProviderDeprecationWarning
from airflow.providers.common.compat.sdk import AirflowException, AirflowSkipException
from airflow.providers.common.compat.sdk import AirflowException, AirflowSkipException, conf
from airflow.providers.common.sql.operators.sql import ( # for _parse_boolean
SQLCheckOperator,
SQLColumnCheckOperator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@
TransferState,
)

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.bigquery_dts import BiqQueryDataTransferServiceHook, get_object_id
from airflow.providers.google.cloud.links.bigquery_dts import BigQueryDataTransferConfigLink
from airflow.providers.google.cloud.operators.cloud_base import GoogleCloudBaseOperator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@

from google.cloud.batch_v1 import Job, Task

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.cloud_batch import CloudBatchHook
from airflow.providers.google.cloud.operators.cloud_base import GoogleCloudBaseOperator
from airflow.providers.google.cloud.triggers.cloud_batch import CloudBatchJobFinishedTrigger
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
from google.api_core.gapic_v1.method import DEFAULT, _MethodDefault
from google.cloud.devtools.cloudbuild_v1.types import Build, BuildTrigger, RepoSource

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.cloud_build import CloudBuildHook
from airflow.providers.google.cloud.links.cloud_build import (
CloudBuildLink,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@
from google.cloud.orchestration.airflow.service_v1 import ImageVersion
from google.cloud.orchestration.airflow.service_v1.types import Environment, ExecuteAirflowCommandResponse

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.cloud_composer import CloudComposerHook
from airflow.providers.google.cloud.links.base import BaseGoogleLink
from airflow.providers.google.cloud.operators.cloud_base import GoogleCloudBaseOperator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@
from google.api_core.exceptions import AlreadyExists
from google.cloud.run_v2 import Job, Service

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.cloud_run import CloudRunHook, CloudRunServiceHook
from airflow.providers.google.cloud.links.cloud_run import CloudRunJobLoggingLink
from airflow.providers.google.cloud.operators.cloud_base import GoogleCloudBaseOperator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@

from googleapiclient.errors import HttpError

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException, BaseHook
from airflow.providers.common.compat.sdk import AirflowException, BaseHook, conf
from airflow.providers.google.cloud.hooks.cloud_sql import CloudSQLDatabaseHook, CloudSQLHook
from airflow.providers.google.cloud.links.cloud_sql import CloudSQLInstanceDatabaseLink, CloudSQLInstanceLink
from airflow.providers.google.cloud.operators.cloud_base import GoogleCloudBaseOperator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,8 @@
from datetime import date, time, timedelta
from typing import TYPE_CHECKING, Any

from airflow.configuration import conf
from airflow.providers.amazon.aws.hooks.base_aws import AwsBaseHook
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.cloud_storage_transfer_service import (
ACCESS_KEY_ID,
AWS_ACCESS_KEY,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@

from googleapiclient.errors import HttpError

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.dataflow import (
DEFAULT_DATAFLOW_LOCATION,
DataflowHook,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@
from google.api_core.retry import exponential_sleep_generator
from googleapiclient.errors import HttpError

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.datafusion import SUCCESS_STATES, DataFusionHook, PipelineStates
from airflow.providers.google.cloud.links.datafusion import (
DataFusionInstanceLink,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
)
from googleapiclient.errors import HttpError

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import conf
from airflow.providers.google.cloud.hooks.dataplex import AirflowDataQualityScanException, DataplexHook
from airflow.providers.google.cloud.links.dataplex import (
DataplexCatalogAspectTypeLink,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,8 @@
from google.api_core.retry import Retry, exponential_sleep_generator
from google.cloud.dataproc_v1 import Batch, Cluster, ClusterStatus, JobStatus

from airflow.configuration import conf
from airflow.exceptions import AirflowProviderDeprecationWarning
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.dataproc import (
DataprocHook,
DataProcJobBuilder,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
from kubernetes.client import V1JobList, models as k8s
from packaging.version import parse as parse_version

from airflow.configuration import conf
from airflow.exceptions import AirflowProviderDeprecationWarning
from airflow.providers.cncf.kubernetes.operators.job import KubernetesJobOperator
from airflow.providers.cncf.kubernetes.operators.kueue import (
Expand All @@ -41,7 +40,7 @@
KubernetesDeleteResourceOperator,
)
from airflow.providers.cncf.kubernetes.utils.pod_manager import OnFinishAction
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.kubernetes_engine import (
GKEHook,
GKEKubernetesHook,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,7 @@
SchemaSettings,
)

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.pubsub import PubSubHook
from airflow.providers.google.cloud.links.pubsub import PubSubSubscriptionLink, PubSubTopicLink
from airflow.providers.google.cloud.operators.cloud_base import GoogleCloudBaseOperator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
from google.api_core.gapic_v1.method import DEFAULT, _MethodDefault
from google.cloud.aiplatform_v1.types import BatchPredictionJob

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.vertex_ai.batch_prediction_job import BatchPredictionJobHook
from airflow.providers.google.cloud.links.vertex_ai import (
VertexAIBatchPredictionJobLink,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
from google.cloud.aiplatform_v1.types.dataset import Dataset
from google.cloud.aiplatform_v1.types.training_pipeline import TrainingPipeline

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.vertex_ai.custom_job import CustomJobHook
from airflow.providers.google.cloud.links.vertex_ai import (
VertexAIModelLink,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@
from google.api_core.gapic_v1.method import DEFAULT, _MethodDefault
from google.cloud.aiplatform_v1 import types

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.vertex_ai.hyperparameter_tuning_job import (
HyperparameterTuningJobHook,
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@
from google.api_core.gapic_v1.method import DEFAULT, _MethodDefault
from google.cloud.aiplatform_v1 import types

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.vertex_ai.pipeline_job import PipelineJobHook
from airflow.providers.google.cloud.links.vertex_ai import (
VertexAIPipelineJobLink,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,8 @@
from datetime import timedelta
from typing import TYPE_CHECKING, Any

from airflow.configuration import conf
from airflow.exceptions import AirflowProviderDeprecationWarning
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator, conf
from airflow.providers.google.cloud.hooks.bigquery import BigQueryHook
from airflow.providers.google.cloud.triggers.bigquery import (
BigQueryTableExistenceTrigger,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,12 @@
from google.api_core.exceptions import NotFound
from google.cloud.orchestration.airflow.service_v1.types import Environment, ExecuteAirflowCommandResponse

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException, AirflowSkipException, BaseSensorOperator
from airflow.providers.common.compat.sdk import (
AirflowException,
AirflowSkipException,
BaseSensorOperator,
conf,
)
from airflow.providers.google.cloud.hooks.cloud_composer import CloudComposerHook
from airflow.providers.google.cloud.triggers.cloud_composer import (
CloudComposerDAGRunTrigger,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@
from collections.abc import Sequence
from typing import TYPE_CHECKING, Any

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator, conf
from airflow.providers.google.cloud.hooks.cloud_storage_transfer_service import (
COUNTERS,
METADATA,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@
from functools import cached_property
from typing import TYPE_CHECKING, Any

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator, PokeReturnValue
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator, PokeReturnValue, conf
from airflow.providers.google.cloud.hooks.dataflow import (
DEFAULT_DATAFLOW_LOCATION,
DataflowHook,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@

from google.cloud.storage.retry import DEFAULT_RETRY

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator, poke_mode_only
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator, conf, poke_mode_only
from airflow.providers.google.cloud.hooks.gcs import GCSHook
from airflow.providers.google.cloud.triggers.gcs import (
GCSBlobTrigger,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@
from google.cloud import pubsub_v1
from google.cloud.pubsub_v1.types import ReceivedMessage

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator
from airflow.providers.common.compat.sdk import AirflowException, BaseSensorOperator, conf
from airflow.providers.google.cloud.hooks.pubsub import PubSubHook
from airflow.providers.google.cloud.triggers.pubsub import PubsubPullTrigger

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@
from google.api_core.exceptions import Conflict
from google.cloud.bigquery import DEFAULT_RETRY, UnknownJob

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.bigquery import BigQueryHook, BigQueryJob
from airflow.providers.google.cloud.links.bigquery import BigQueryTableLink
from airflow.providers.google.cloud.triggers.bigquery import BigQueryInsertJobTrigger
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@
)
from google.cloud.bigquery.table import EncryptionConfiguration, Table, TableReference

from airflow.configuration import conf
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.bigquery import BigQueryHook, BigQueryJob
from airflow.providers.google.cloud.hooks.gcs import GCSHook
from airflow.providers.google.cloud.links.bigquery import BigQueryTableLink
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,8 @@
from tempfile import NamedTemporaryFile
from typing import TYPE_CHECKING, Any

from airflow.configuration import conf
from airflow.providers.amazon.aws.hooks.s3 import S3Hook
from airflow.providers.common.compat.sdk import AirflowException
from airflow.providers.common.compat.sdk import AirflowException, conf
from airflow.providers.google.cloud.hooks.cloud_storage_transfer_service import (
ACCESS_KEY_ID,
AWS_ACCESS_KEY,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@
from google.auth.transport.requests import AuthorizedSession
from google.oauth2 import service_account

from airflow.configuration import conf
from airflow.exceptions import AirflowProviderDeprecationWarning
from airflow.providers.common.compat.sdk import conf
from airflow.providers.google.common.deprecated import deprecated
from airflow.providers.google.common.utils.id_token_credentials import get_default_id_token_credentials

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

def create_connection_request(connection_id: str, connection: dict[str, Any], is_composer: bool = False):
if is_composer:
from airflow.configuration import conf
from airflow.providers.common.compat.sdk import conf
from airflow.providers.google.cloud.hooks.cloud_composer import CloudComposerHook

hook = CloudComposerHook()
Expand Down Expand Up @@ -59,7 +59,7 @@ def create_connection_request(connection_id: str, connection: dict[str, Any], is

def delete_connection_request(connection_id: str, is_composer: bool = False):
if is_composer:
from airflow.configuration import conf
from airflow.providers.common.compat.sdk import conf
from airflow.providers.google.cloud.hooks.cloud_composer import CloudComposerHook

hook = CloudComposerHook()
Expand Down
Loading