ferruzzi commented on code in PR #55308: URL: https://github.com/apache/airflow/pull/55308#discussion_r2334278204
########## providers/smtp/tests/unit/smtp/hooks/test_smtp.py: ########## @@ -22,17 +22,49 @@ import smtplib import tempfile from email.mime.application import MIMEApplication -from unittest.mock import Mock, call, patch +from unittest import mock +from unittest.mock import AsyncMock, Mock, call, patch +import aiosmtplib import pytest from airflow.exceptions import AirflowException -from airflow.models import Connection from airflow.providers.smtp.hooks.smtp import SmtpHook, build_xoauth2_string +from tests_common.test_utils.version_compat import AIRFLOW_V_3_1_PLUS + +try: + from airflow.sdk import Connection Review Comment: Oh, are you saying instead of the try/except, it needs to be something like: ``` if task-sdk > 3.0.6: from airflow.sdk import Connection else: from airflow.models.connection import Connection ``` -- 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: commits-unsubscr...@airflow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org