Avihais12344 opened a new issue, #41420:
URL: https://github.com/apache/airflow/issues/41420

   ### Description
   
   Instead of using `list` for holding the tags of a specific dag (as we can 
see at the 
[docs](https://airflow.apache.org/docs/apache-airflow/stable/_api/airflow/models/dag/index.html#airflow.models.dag.DAG)),
 I suggest using `set` instead, specifically [`MutableSet` for the type 
hinting](https://docs.python.org/3/library/collections.abc.html#collections.abc.MutableSet),
 and [python 
`set`](https://docs.python.org/3/tutorial/datastructures.html#sets) as the 
default implementation.
   
   ### Use case/motivation
   
   I would want to add multiple tags (even the same ones) faster, without 
worrying about duplicates, and reduce the memory usage because of it.
   
   ### Related issues
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [X] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


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