EnxDev commented on code in PR #43967:
URL: https://github.com/apache/superset/pull/43967#discussion_r3977500934
##########
superset-frontend/src/pages/DatasetList/index.tsx:
##########
@@ -613,6 +731,35 @@ const DatasetList: FunctionComponent<DatasetListProps> = ({
setDatasetCurrentlyDuplicating(dataset);
}, []);
+ const fetchBulkRelatedObjects = useCallback((selected: Dataset[]) => {
+ // Semantic views delete through their own endpoint and have no
+ // related_objects lookup, so only regular datasets are checked.
+ const ids = selected.filter(d => !isSemanticView(d)).map(({ id }) => id);
Review Comment:
Could we account for semantic-view dependents here as well? `Slice` supports
`datasource_type="semantic_view"`, and the semantic-view delete path
hard-deletes the view without cascading its charts. In a mixed selection,
filtering these rows out can let the regular-dataset lookup return zero and
show “No charts or dashboards depend…” even though charts depend on a selected
semantic view. A separate typed lookup may be safest because dataset and
semantic-view IDs can overlap; alternatively, could we treat the impact as
unknown and suppress the no-dependents message whenever semantic views are
selected?
--
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]