Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove Provider Deprecations in Trino #44717

Merged
merged 4 commits into from
Dec 10, 2024
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
9 changes: 9 additions & 0 deletions providers/src/airflow/providers/trino/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,15 @@
Changelog
---------

main
....

.. warning::
All deprecated classes, parameters and features have been removed from the {provider_name} provider package.
The following breaking changes were introduced:

* Remove ``TrinoOperator`` class from airflow.providers.trino.operators.trino. Please use ``airflow.providers.common.sql.operators.sql.SQLExecuteQueryOperator```

5.9.0
.....

Expand Down
16 changes: 0 additions & 16 deletions providers/src/airflow/providers/trino/operators/__init__.py

This file was deleted.

80 changes: 0 additions & 80 deletions providers/src/airflow/providers/trino/operators/trino.py

This file was deleted.

5 changes: 0 additions & 5 deletions providers/src/airflow/providers/trino/provider.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,6 @@ integrations:
- /docs/apache-airflow-providers-trino/operators/trino.rst
tags: [software]

operators:
- integration-name: Trino
python-modules:
- airflow.providers.trino.operators.trino

asset-uris:
- schemes: [trino]
handler: airflow.providers.trino.assets.trino.sanitize_uri
Expand Down
4 changes: 2 additions & 2 deletions providers/tests/integration/trino/hooks/test_trino.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@

import pytest

from airflow.providers.common.sql.operators.sql import SQLExecuteQueryOperator
from airflow.providers.trino.hooks.trino import TrinoHook
from airflow.providers.trino.operators.trino import TrinoOperator


@pytest.mark.integration("trino")
Expand Down Expand Up @@ -50,7 +50,7 @@ def test_should_record_records_with_kerberos_auth(self):

@mock.patch.dict("os.environ", AIRFLOW_CONN_TRINO_DEFAULT="trino://airflow@trino:8080/")
def test_openlineage_methods(self):
op = TrinoOperator(task_id="trino_test", sql="SELECT name FROM tpch.sf1.customer LIMIT 3")
op = SQLExecuteQueryOperator(task_id="trino_test", sql="SELECT name FROM tpch.sf1.customer LIMIT 3")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should add conn_id="trino_default" as this test is failing now.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right it was removed by mistake.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ya I'll correct that id

op.execute({})
lineage = op.get_openlineage_facets_on_start()
assert lineage.inputs[0].namespace == "trino://trino:8080"
Expand Down
16 changes: 0 additions & 16 deletions providers/tests/trino/operators/__init__.py

This file was deleted.

113 changes: 0 additions & 113 deletions providers/tests/trino/operators/test_trino.py

This file was deleted.