File tree Expand file tree Collapse file tree
providers/google/src/airflow/providers/google/cloud/hooks Expand file tree Collapse file tree Original file line number Diff line number Diff line change 5050from googleapiclient .discovery import Resource , build
5151
5252from airflow .exceptions import AirflowProviderDeprecationWarning
53- from airflow .providers .apache .beam .hooks .beam import BeamHook , BeamRunnerType , beam_options_to_args
54- from airflow .providers .common .compat .sdk import AirflowException , timeout
53+ from airflow .providers .common .compat .sdk import (
54+ AirflowException ,
55+ AirflowOptionalProviderFeatureException ,
56+ timeout ,
57+ )
58+
59+ try :
60+ from airflow .providers .apache .beam .hooks .beam import BeamHook , BeamRunnerType , beam_options_to_args
61+ except ImportError as e :
62+ raise AirflowOptionalProviderFeatureException (
63+ "Failed to import apache-airflow-providers-apache-beam. "
64+ "To use the Dataflow service with Apache Beam pipelines, please install the apache-beam provider: "
65+ "pip install apache-airflow-providers-apache-beam"
66+ ) from e
5567from airflow .providers .google .common .hooks .base_google import (
5668 PROVIDE_PROJECT_ID ,
5769 GoogleBaseAsyncHook ,
You can’t perform that action at this time.
0 commit comments