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



##########
File path: airflow/models/skipmixin.py
##########
@@ -114,10 +114,7 @@ def skip(
         session.commit()
 
         # SkipMixin may not necessarily have a task_id attribute. Only store 
to XCom if one is available.
-        try:
-            task_id = self.task_id
-        except AttributeError:
-            task_id = None
+        task_id: Optional[str] = getattr(self, 'task_id')

Review comment:
       ```suggestion
           task_id: Optional[str] = getattr(self, 'task_id', None)
   ```




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