jlaportebot commented on PR #66490:
URL: https://github.com/apache/airflow/pull/66490#issuecomment-4483800594

   I'm closing this PR as the underlying bug has already been fixed on the main 
branch with a different approach. The main branch now uses:
   
   ```python
   if smtp_client is not None:
       smtp_client = cast("smtplib.SMTP_SSL | smtplib.SMTP", smtp_client)
       status = smtp_client.noop()
       if status[0] == 250:
   ```
   
   This is a cleaner solution than my `isinstance` approach since it uses 
`cast` for mypy type narrowing rather than a runtime check. Main also includes 
parametrized tests for the noop responses.
   
   Thanks for the review and feedback!


-- 
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]

Reply via email to