You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/12/03 16:20:17 UTC

[GitHub] [airflow] uranusjr commented on a change in pull request #20019: Change ParamsDict to a MutableMapping subclass

uranusjr commented on a change in pull request #20019:
URL: https://github.com/apache/airflow/pull/20019#discussion_r762072353



##########
File path: airflow/models/param.py
##########
@@ -99,16 +99,17 @@ def has_value(self) -> bool:
         return not isinstance(self.value, NoValueSentinel)
 
 
-class ParamsDict(dict):
+class ParamsDict(MutableMapping):
     """
     Class to hold all params for dags or tasks. All the keys are strictly string and values
     are converted into Param's object if they are not already. This class is to replace param's
     dictionary implicitly and ideally not needed to be used directly.
     """
 
+    __slots__ = ['__dict__', 'supresss_exception']

Review comment:
       ```suggestion
       __slots__ = ['__dict', 'supresss_exception']
   ```
   
   I think?




-- 
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-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org