ephraimbuddy commented on code in PR #25471:
URL: https://github.com/apache/airflow/pull/25471#discussion_r935730738


##########
airflow/callbacks/callback_requests.py:
##########
@@ -74,8 +75,8 @@ def __init__(
         self.is_failure_callback = is_failure_callback
 
     def to_json(self) -> str:
-        dict_obj = self.__dict__.copy()
-        dict_obj["simple_task_instance"] = 
dict_obj["simple_task_instance"].__dict__
+        dict_obj = copy.deepcopy(self.__dict__)

Review Comment:
   I changed to `self.simple_task_instance.as_dict()` and it solved the issue I 
was having before that made me use deepcopy. Previously with just copy, my test 
was not passing as input != result.
   Thanks



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