Skip to content

Commit

Permalink
Allow DW to use proposed API (#15820)
Browse files Browse the repository at this point in the history
  • Loading branch information
DonJayamanne authored Aug 10, 2024
1 parent 109457d commit 2a11eb0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/platform/common/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export const NOTEBOOK_SELECTOR = [

export const CodespaceExtensionId = 'GitHub.codespaces';
export const JVSC_EXTENSION_ID = 'ms-toolsai.jupyter';
export const DATA_WRANGLER_EXTENSION_ID = 'ms-toolsai.datawrangler';
export const POWER_TOYS_EXTENSION_ID = 'ms-toolsai.vscode-jupyter-powertoys';
export const JUPYTER_HUB_EXTENSION_ID = 'ms-toolsai.jupyter-hub';
export const AppinsightsKey = '0c6ae279ed8443289764825290e4f9e2-1a736e7c-1324-4338-be46-fc2a58ae4d14-7255';
Expand Down
9 changes: 7 additions & 2 deletions src/standalone/api/kernels/kernel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,12 @@ import { StopWatch } from '../../../platform/common/utils/stopWatch';
import { Deferred, createDeferred, sleep } from '../../../platform/common/utils/async';
import { once } from '../../../platform/common/utils/events';
import { logger } from '../../../platform/logging';
import { JVSC_EXTENSION_ID, POWER_TOYS_EXTENSION_ID, PYTHON_LANGUAGE } from '../../../platform/common/constants';
import {
DATA_WRANGLER_EXTENSION_ID,
JVSC_EXTENSION_ID,
POWER_TOYS_EXTENSION_ID,
PYTHON_LANGUAGE
} from '../../../platform/common/constants';
import { ChatMime, generatePythonCodeToInvokeCallback } from '../../../kernels/chat/generator';
import {
isDisplayIdTrackedForExtension,
Expand Down Expand Up @@ -244,7 +249,7 @@ class WrappedKernelPerExtension extends DisposableBase implements Kernel {
},
onDidChangeStatus: that.onDidChangeStatus.bind(this),
get onDidReceiveDisplayUpdate() {
if (![JVSC_EXTENSION_ID, POWER_TOYS_EXTENSION_ID].includes(extensionId)) {
if (![JVSC_EXTENSION_ID, POWER_TOYS_EXTENSION_ID, DATA_WRANGLER_EXTENSION_ID].includes(extensionId)) {
throw new Error(`Proposed API is not supported for extension ${extensionId}`);
}

Expand Down

0 comments on commit 2a11eb0

Please sign in to comment.