Jorricks commented on a change in pull request #16633:
URL: https://github.com/apache/airflow/pull/16633#discussion_r664518731



##########
File path: tests/serialization/test_dag_serialization.py
##########
@@ -861,6 +892,30 @@ def __init__(self, do_xcom_push=False, **kwargs):
 
         assert serialized_op.do_xcom_push is False
 
+    def test_operator_custom_serialized_fields_present(self):
+        class MyOperator(BaseOperator):
+            __serialized_fields: Optional[frozenset] = None
+
+            def __init__(self, a_dictionary_value: Dict, **kwargs):
+                super().__init__(**kwargs)
+                self.a_dictionary_value = a_dictionary_value

Review comment:
       This is a valid work around. 
   I didn't check that this wouldn't cause issues.
   
   Shall I modify the PR so that we incorporate these tests to make it a bit 
more visible that this is an option?




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