bito-code-review[bot] commented on code in PR #40473:
URL: https://github.com/apache/superset/pull/40473#discussion_r3358883587


##########
superset/mcp_service/dashboard/tool/get_dashboard_info.py:
##########
@@ -247,6 +249,21 @@ async def get_dashboard_info(
                     result.is_permalink_state,
                 )
             )
+            # When permalink_key is supplied and the caller did not explicitly
+            # override select_columns, ensure filter_state is present so the
+            # caller gets the data they came for.
+            effective_select_columns = list(request.select_columns)
+            if (
+                request.permalink_key
+                and effective_select_columns == 
list(DEFAULT_GET_DASHBOARD_INFO_COLUMNS)
+                and "filter_state" not in effective_select_columns

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Dead code introduced</b></div>
   <div id="fix">
   
   Remove the redundant `and "filter_state" not in effective_select_columns` 
condition since the default columns already include 'filter_state'.
   </div>
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #689af0</i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a 
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



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

Reply via email to