aminghadersohi commented on code in PR #44796:
URL: https://github.com/apache/superset/pull/44796#discussion_r4141119566
##########
superset/mcp_service/dashboard/tool/apply_dashboard_filters.py:
##########
@@ -73,6 +74,8 @@ def _publish_filters_applied(dashboard_id: int,
permalink_key: str) -> bool:
from superset.websocket.channel import get_realtime_principal
try:
+ if not current_app.config.get("WEBSOCKET_ENABLE"):
Review Comment:
Valid. The websocket channel cookie is only minted when
`can_access_realtime_notifications()` (`can_read` on `Realtime`) passes
(`superset/websocket/channel.py`, `set_ws_channel_cookie`), so a caller without
it has no socket to receive the nudge. Fixed in
8084c271e59e7d5f51f891489c45505b675c14c9: `_publish_filters_applied` now checks
the same permission and returns `False` without publishing when it is missing.
Tests cover both the permitted case (publish, `true`) and the
missing-permission case (no publish, `false`).
--
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]