From 63adfd4d389bd8d424b774fdd2ad84bf757d2c05 Mon Sep 17 00:00:00 2001 From: Vasu Bhog Date: Fri, 18 Sep 2020 20:35:25 -0500 Subject: [PATCH] Fix PySpark kernel connection change (#12494) --- src/sql/workbench/contrib/notebook/browser/notebookActions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sql/workbench/contrib/notebook/browser/notebookActions.ts b/src/sql/workbench/contrib/notebook/browser/notebookActions.ts index fe566dbe76..2c2ab8f465 100644 --- a/src/sql/workbench/contrib/notebook/browser/notebookActions.ts +++ b/src/sql/workbench/contrib/notebook/browser/notebookActions.ts @@ -512,7 +512,7 @@ export class AttachToDropdown extends SelectBox { //Changes kernel based on connection attached to if (this.model.kernelAliases.includes(connectionProfile.serverCapabilities.notebookKernelAlias)) { this.model.changeKernel(connectionProfile.serverCapabilities.notebookKernelAlias); - } else { + } else if (this.model.clientSession.kernel.name === 'SQL') { this.model.changeKernel('SQL'); } return true;