diff --git a/public/app/features/explore/state/query.ts b/public/app/features/explore/state/query.ts index c7a38911f17..13ca14bd7a5 100644 --- a/public/app/features/explore/state/query.ts +++ b/public/app/features/explore/state/query.ts @@ -660,8 +660,10 @@ export const processQueryResponse = ( return state; } - // For Angular editors - state.eventBridge.emit(PanelEvents.dataError, error); + // Send error to Angular editors + if (state.datasourceInstance?.components?.QueryCtrl) { + state.eventBridge.emit(PanelEvents.dataError, error); + } } if (!request) { @@ -673,7 +675,6 @@ export const processQueryResponse = ( // Send legacy data to Angular editors if (state.datasourceInstance?.components?.QueryCtrl) { const legacy = series.map((v) => toLegacyResponseData(v)); - state.eventBridge.emit(PanelEvents.dataReceived, legacy); }