rusackas commented on code in PR #37625:
URL: https://github.com/apache/superset/pull/37625#discussion_r2771439799


##########
superset-frontend/src/explore/components/ExploreViewContainer/index.tsx:
##########
@@ -840,14 +980,15 @@ function ExploreViewContainer(props) {
               />
             </span>
           </div>
+          {/* eslint-disable @typescript-eslint/no-explicit-any -- 
DataSourcePanel uses narrower types that are compatible at runtime */}
           <DataSourcePanel
             formData={props.form_data}
-            datasource={props.datasource}
-            controls={props.controls}
-            actions={props.actions}
+            datasource={props.datasource as any}
+            controls={props.controls as any}
+            actions={props.actions as any}

Review Comment:
   Investigated in b1a3ce4e84 but keeping the casts for now. The type 
incompatibilities are fundamental:
   
   1. `Datasource.columns` is `ColumnMeta[]` but `IDatasource` expects 
`DatasourcePanelColumn[]` (which requires `uuid`)
   2. `ControlStateMapping` has dynamic keys but `Props.controls` expects `{ 
datasource: DatasourceControl }`
   3. `DispatchProps.actions` is `Record<string, (...args: any[]) => any>` but 
doesn't guarantee `setControlValue`
   
   Fixing these properly would require changes across multiple type 
definitions. The eslint-disable comment documents that these are 
runtime-compatible but structurally incompatible types.



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