Skip to content

Commit

Permalink
Remove deprecated modules (#25543)
Browse files Browse the repository at this point in the history
  • Loading branch information
vincbeck committed Aug 5, 2022
1 parent e81b27e commit 029e3ae
Show file tree
Hide file tree
Showing 82 changed files with 186 additions and 2,059 deletions.
11 changes: 8 additions & 3 deletions airflow/contrib/operators/emr_add_steps_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.emr_add_steps`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.emr`."""

import warnings

from airflow.providers.amazon.aws.operators.emr_add_steps import EmrAddStepsOperator # noqa
try:
from airflow.providers.amazon.aws.operators.emr import EmrAddStepsOperator
except ImportError:
from airflow.providers.amazon.aws.operators.emr_add_steps import ( # type: ignore[no-redef] # noqa
EmrAddStepsOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.emr_add_steps`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.emr`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/emr_create_job_flow_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,19 @@
# specific language governing permissions and limitations
# under the License.

"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.emr_create_job_flow`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.emr`."""

import warnings

from airflow.providers.amazon.aws.operators.emr_create_job_flow import EmrCreateJobFlowOperator # noqa
try:
from airflow.providers.amazon.aws.operators.emr import EmrCreateJobFlowOperator
except ImportError:
from airflow.providers.amazon.aws.operators.emr_create_job_flow import ( # type: ignore[no-redef] # noqa
EmrCreateJobFlowOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.emr_create_job_flow`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.emr`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/emr_terminate_job_flow_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,20 @@
# under the License.
"""
This module is deprecated.
Please use :mod:`airflow.providers.amazon.aws.operators.emr_terminate_job_flow`.
Please use :mod:`airflow.providers.amazon.aws.operators.emr`.
"""

import warnings

from airflow.providers.amazon.aws.operators.emr_terminate_job_flow import EmrTerminateJobFlowOperator # noqa
try:
from airflow.providers.amazon.aws.operators.emr import EmrTerminateJobFlowOperator
except ImportError:
from airflow.providers.amazon.aws.operators.emr_terminate_job_flow import ( # type: ignore[no-redef] # noqa
EmrTerminateJobFlowOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.emr_terminate_job_flow`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.emr`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/s3_copy_object_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.s3_copy_object`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.s3`."""

import warnings

from airflow.providers.amazon.aws.operators.s3_copy_object import S3CopyObjectOperator # noqa
try:
from airflow.providers.amazon.aws.operators.s3 import S3CopyObjectOperator
except ImportError:
from airflow.providers.amazon.aws.operators.s3_copy_object import ( # type: ignore[no-redef] # noqa
S3CopyObjectOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.s3_copy_object`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.s3`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/s3_delete_objects_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,20 @@
# under the License.
"""
This module is deprecated.
Please use :mod:`airflow.providers.amazon.aws.operators.s3_delete_objects`.
Please use :mod:`airflow.providers.amazon.aws.operators.s3`.
"""

import warnings

from airflow.providers.amazon.aws.operators.s3_delete_objects import S3DeleteObjectsOperator # noqa
try:
from airflow.providers.amazon.aws.operators.s3 import S3DeleteObjectsOperator
except ImportError:
from airflow.providers.amazon.aws.operators.s3_delete_objects import ( # type: ignore[no-redef] # noqa
S3DeleteObjectsOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.s3_delete_objects`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.s3`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/s3_list_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.s3_list`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.s3`."""

import warnings

from airflow.providers.amazon.aws.operators.s3_list import S3ListOperator # noqa
try:
from airflow.providers.amazon.aws.operators.s3 import S3ListOperator
except ImportError:
from airflow.providers.amazon.aws.operators.s3_list import ( # type: ignore[no-redef] # noqa
S3ListOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.s3_list`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.s3`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/sagemaker_base_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker_base`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker`."""

import warnings

from airflow.providers.amazon.aws.operators.sagemaker_base import SageMakerBaseOperator # noqa
try:
from airflow.providers.amazon.aws.operators.sagemaker import SageMakerBaseOperator
except ImportError:
from airflow.providers.amazon.aws.operators.sagemaker_base import ( # type: ignore[no-redef] # noqa
SageMakerBaseOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker_base`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)
14 changes: 8 additions & 6 deletions airflow/contrib/operators/sagemaker_endpoint_config_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,20 @@
# under the License.
"""
This module is deprecated.
Please use `airflow.providers.amazon.aws.operators.sagemaker_endpoint_config`.
Please use `airflow.providers.amazon.aws.operators.sagemaker`.
"""

import warnings

from airflow.providers.amazon.aws.operators.sagemaker_endpoint_config import ( # noqa
SageMakerEndpointConfigOperator,
)
try:
from airflow.providers.amazon.aws.operators.sagemaker import SageMakerEndpointConfigOperator
except ImportError:
from airflow.providers.amazon.aws.operators.sagemaker_endpoint_config import ( # type: ignore[no-redef] # noqa
SageMakerEndpointConfigOperator,
)

warnings.warn(
"This module is deprecated. "
"Please use `airflow.providers.amazon.aws.operators.sagemaker_endpoint_config`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/sagemaker_endpoint_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,20 @@
# under the License.
"""
This module is deprecated.
Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker_endpoint`.
Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker`.
"""

import warnings

from airflow.providers.amazon.aws.operators.sagemaker_endpoint import SageMakerEndpointOperator # noqa
try:
from airflow.providers.amazon.aws.operators.sagemaker import SageMakerEndpointOperator
except ImportError:
from airflow.providers.amazon.aws.operators.sagemaker_endpoint import ( # type: ignore[no-redef] # noqa
SageMakerEndpointOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker_endpoint`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/sagemaker_model_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker_model`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker`."""

import warnings

from airflow.providers.amazon.aws.operators.sagemaker_model import SageMakerModelOperator # noqa
try:
from airflow.providers.amazon.aws.operators.sagemaker import SageMakerModelOperator
except ImportError:
from airflow.providers.amazon.aws.operators.sagemaker_model import ( # type: ignore[no-redef] # noqa
SageMakerModelOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker_model`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/sagemaker_training_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker_training`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker`."""

import warnings

from airflow.providers.amazon.aws.operators.sagemaker_training import SageMakerTrainingOperator # noqa
try:
from airflow.providers.amazon.aws.operators.sagemaker import SageMakerTrainingOperator
except ImportError:
from airflow.providers.amazon.aws.operators.sagemaker_training import ( # type: ignore[no-redef] # noqa
SageMakerTrainingOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker_training`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/sagemaker_transform_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker_transform`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker`."""

import warnings

from airflow.providers.amazon.aws.operators.sagemaker_transform import SageMakerTransformOperator # noqa
try:
from airflow.providers.amazon.aws.operators.sagemaker import SageMakerTransformOperator
except ImportError:
from airflow.providers.amazon.aws.operators.sagemaker_transform import ( # type: ignore[no-redef] # noqa
SageMakerTransformOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker_transform`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/operators/sagemaker_tuning_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker_tuning`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.operators.sagemaker`."""

import warnings

from airflow.providers.amazon.aws.operators.sagemaker_tuning import SageMakerTuningOperator # noqa
try:
from airflow.providers.amazon.aws.operators.sagemaker import SageMakerTuningOperator
except ImportError:
from airflow.providers.amazon.aws.operators.sagemaker_tuning import ( # type: ignore[no-redef] # noqa
SageMakerTuningOperator,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker_tuning`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.operators.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)
9 changes: 6 additions & 3 deletions airflow/contrib/sensors/emr_base_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,17 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.emr_base`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.emr`."""

import warnings

from airflow.providers.amazon.aws.sensors.emr_base import EmrBaseSensor # noqa
try:
from airflow.providers.amazon.aws.sensors.emr import EmrBaseSensor
except ImportError:
from airflow.providers.amazon.aws.sensors.emr_base import EmrBaseSensor # type: ignore[no-redef] # noqa

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.emr_base`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.emr`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/sensors/emr_job_flow_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.emr_job_flow`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.emr`."""

import warnings

from airflow.providers.amazon.aws.sensors.emr_job_flow import EmrJobFlowSensor # noqa
try:
from airflow.providers.amazon.aws.sensors.emr import EmrJobFlowSensor
except ImportError:
from airflow.providers.amazon.aws.sensors.emr_job_flow import ( # type: ignore[no-redef] # noqa
EmrJobFlowSensor,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.emr_job_flow`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.emr`.",
DeprecationWarning,
stacklevel=2,
)
9 changes: 6 additions & 3 deletions airflow/contrib/sensors/emr_step_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,17 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.emr_step`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.emr`."""

import warnings

from airflow.providers.amazon.aws.sensors.emr_step import EmrStepSensor # noqa
try:
from airflow.providers.amazon.aws.sensors.emr import EmrStepSensor
except ImportError:
from airflow.providers.amazon.aws.sensors.emr_step import EmrStepSensor # type: ignore[no-redef] # noqa

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.emr_step`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.emr`.",
DeprecationWarning,
stacklevel=2,
)
11 changes: 8 additions & 3 deletions airflow/contrib/sensors/sagemaker_base_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,19 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.sagemaker_base`."""
"""This module is deprecated. Please use :mod:`airflow.providers.amazon.aws.sensors.sagemaker`."""

import warnings

from airflow.providers.amazon.aws.sensors.sagemaker_base import SageMakerBaseSensor # noqa
try:
from airflow.providers.amazon.aws.sensors.sagemaker import SageMakerBaseSensor
except ImportError:
from airflow.providers.amazon.aws.sensors.sagemaker_base import ( # type: ignore[no-redef] # noqa
SageMakerBaseSensor,
)

warnings.warn(
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.sagemaker_base`.",
"This module is deprecated. Please use `airflow.providers.amazon.aws.sensors.sagemaker`.",
DeprecationWarning,
stacklevel=2,
)

0 comments on commit 029e3ae

Please sign in to comment.