dstandish commented on code in PR #27849:
URL: https://github.com/apache/airflow/pull/27849#discussion_r1030178492
##########
airflow/www/utils.py:
##########
@@ -717,10 +717,10 @@ def clean_column_names():
clean_column_names()
# Support for AssociationProxy in search and list columns
- for desc in self.obj.__mapper__.all_orm_descriptors:
+ for obj_attr, desc in self.obj.__mapper__.all_orm_descriptors.items():
if not isinstance(desc, AssociationProxy):
continue
- proxy_instance = getattr(self.obj, desc.value_attr)
+ proxy_instance = getattr(self.obj, obj_attr)
Review Comment:
previously the code assumed that the attr name where the proxy is stored on
the object (`obj_attr`) is the same as the name of the field on the remote
object (`desc.value_attr`). but it doesn't have to be the case. and here we
store the reference to `task_instance_note.content` under the attr `notes`
--
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]