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


##########
superset-frontend/plugins/plugin-chart-echarts/src/Butterfly/constants.ts:
##########
@@ -0,0 +1,31 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import {
+  DEFAULT_LEGEND_FORM_DATA,
+  DEFAULT_TITLE_FORM_DATA,
+} from '../constants';
+import { defaultXAxis } from '../defaults';
+
+export const DEFAULT_FORM_DATA = {
+  ...DEFAULT_LEGEND_FORM_DATA,
+  ...DEFAULT_TITLE_FORM_DATA,
+  showValue: true,
+  truncateXAxis: true,

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Dead default without control</b></div>
   <div id="fix">
   
   The `truncateXAxis: true` property at line 29 is dead code. This property is 
not exposed as a configurable control in `controlPanel.tsx` and is not consumed 
in `transformProps.ts` — only `showValue` and `xAxisLabelRotation` are 
extracted from formData. Comparing against the similar `Bubble` chart (which 
uses `truncateXAxis` in both controlPanel and transformProps), this Butterfly 
implementation is incomplete and the default cannot be changed by users.
   </div>
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #ce7ea6</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



##########
superset-frontend/packages/superset-ui-core/src/chart/types/VizType.ts:
##########
@@ -60,6 +61,7 @@ export enum VizType {
   TimePivot = 'time_pivot',
   TimeTable = 'time_table',
   Timeseries = 'echarts_timeseries',
+  Tornado = 'tornado',

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>CWE-11234: Missing Chart Plugin Implementation</b></div>
   <div id="fix">
   
   The `Tornado` enum entry references `'tornado'` but no Tornado chart plugin 
implementation exists anywhere in the codebase (no plugin in 
`plugin-chart-echarts`, no import in `MainPreset.ts`, and no backend 
implementation). This creates an unusable enum value — if a user selects 
'Tornado' as a visualization, the system has no plugin to handle it. Compare 
with `Butterfly` which is fully implemented and registered. Either remove this 
enum entry or implement the complete Tornado chart plugin first. (See also: 
[CWE-11234](https://cwe.mitre.org/data/definitions/11234.html))
   </div>
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #ce7ea6</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