manipatnam commented on code in PR #67551:
URL: https://github.com/apache/airflow/pull/67551#discussion_r3311223730
##########
airflow-core/src/airflow/api_fastapi/common/parameters.py:
##########
@@ -582,6 +585,16 @@ def _resolve(self) -> list[tuple[str, ColumnElement,
bool]]:
replacement = self.to_replace.get(lstriped_orderby,
lstriped_orderby)
if isinstance(replacement, str):
lstriped_orderby = replacement
+ elif isinstance(replacement, list):
+ # Compound sort: expand the list into multiple sort
entries.
+ # Each column's ORM key becomes its attr_name so that
+ # row_value() can read the corresponding attribute via
+ # getattr(row, attr_name) without further to_replace
lookups.
+ is_desc = order_by_value.startswith("-")
+ for col in replacement:
+ col_attr_name = getattr(col, "key", attr_name)
Review Comment:
Good catch, removed it
--
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]