sadpandajoe commented on code in PR #43575:
URL: https://github.com/apache/superset/pull/43575#discussion_r3904249331
##########
superset/models/dashboard.py:
##########
@@ -378,43 +378,111 @@ def position(self) -> dict[str, Any]:
return {}
@property
- def tabs(self) -> dict[str, Any]:
+ def tabs(self) -> dict[str, Any]: # noqa: C901
+ if not isinstance(self.position, dict):
Review Comment:
Returning `{}` for a JSON-valid non-mapping layout turns the former failure
into a response without `all_tabs` or `tab_tree`. The alert report modal calls
`tabTree.map`, so opening its tab picker now fails instead of receiving an
empty option list. Should malformed-layout exits return the normal empty
payload shape (`all_tabs: {}`, `tab_tree: []`)?
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]