eladkal commented on code in PR #22974: URL: https://github.com/apache/airflow/pull/22974#discussion_r849534845
########## airflow/operators/dummy_operator.py: ########## @@ -15,12 +15,24 @@ # 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.operators.dummy`.""" +"""This module is deprecated. Please use :mod:`airflow.operators.empty`.""" import warnings -from airflow.operators.dummy import DummyOperator # noqa +from airflow.operators.empty import EmptyOperator warnings.warn( - "This module is deprecated. Please use `airflow.operators.dummy`.", DeprecationWarning, stacklevel=2 + "This module is deprecated. Please use `airflow.operators.empty`.", DeprecationWarning, stacklevel=2 ) + + +class DummyOperator(EmptyOperator): Review Comment: There was a [failure](https://github.com/apache/airflow/runs/6008279385?check_suite_focus=true#step:8:3222) in CI: ` FAILED tests/always/test_deprecations.py::TestDeprecations::test_warning_on_import[airflow.operators.empty.EmptyOperator-airflow.operators.dummy_operator.DummyOperator]` I'm not sure why it raises now and not in the deprecation PR :\ ? But in any case added handling for both `dummy.py` and `dummy_operator.py` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
