Lee-W commented on issue #54714:
URL: https://github.com/apache/airflow/issues/54714#issuecomment-3717975763

   > I would like to share some thoughts based on the PR review. Feel free to 
correct me if my understanding is wrong. I think the purpose to introduce these 
ruff rules is to streamline the migration of Airflow 2 DAGs to Airflow 3 DAGs. 
So, our focus should probably be the public API that use to define a DAG.
   > 
   > It looks like the classes/functions/constants defined in the `_internal` 
module under the `sdk` is not designated for DAG authoring but those are used 
internally in Airflow. So, these could be the first to exclude from the list.
   > 
   > `airflow.sdk.io` and `airflow.sdk.timezone` contain utility functions that 
can probably be used to define a task. However, if I understand correctly, 
`sdk.execution_time` is designated for Airflow internal functionality. If that 
is the case, we should probably exclude `airflow.sdk.execution_time.macros` as 
well.
   > 
   > Then, `airflow.sdk.BaseOperator` and 
`airflow.sdk.bases.notifier.BaseNotifier` (or `airflow.sdk.BaseNotifier`) are 
the ones we should include because these can be used to define custom operator 
or notifier.
   
   Instead of removing those rules, we can add a message at the end to warn 
users about using these methods. If these rules are leftover from Airflow 2 and 
cannot simply be removed, we can suggest our users to follow we want them to do.


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