From f8ff0626d99b94561fd9c52fbef8365ef680550b Mon Sep 17 00:00:00 2001 From: Karthik chakravarthy <88904658+kcheekuri@users.noreply.github.com> Date: Wed, 30 Aug 2023 15:54:20 -0400 Subject: [PATCH] Remove token from the URL for the websocket connections (#1591) --- src/Explorer/Notebook/NotebookComponent/epics.ts | 3 --- src/Terminal/JupyterLabAppFactory.ts | 7 +++---- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/src/Explorer/Notebook/NotebookComponent/epics.ts b/src/Explorer/Notebook/NotebookComponent/epics.ts index c09172bcf..4761cbeee 100644 --- a/src/Explorer/Notebook/NotebookComponent/epics.ts +++ b/src/Explorer/Notebook/NotebookComponent/epics.ts @@ -100,9 +100,6 @@ const addInitialCodeCellEpic = ( */ const formWebSocketURL = (serverConfig: NotebookServiceConfig, kernelId: string, sessionId?: string): string => { const params = new URLSearchParams(); - if (serverConfig.token) { - params.append("token", serverConfig.token); - } if (sessionId) { params.append("session_id", sessionId); } diff --git a/src/Terminal/JupyterLabAppFactory.ts b/src/Terminal/JupyterLabAppFactory.ts index da28d10ae..a07bdeb76 100644 --- a/src/Terminal/JupyterLabAppFactory.ts +++ b/src/Terminal/JupyterLabAppFactory.ts @@ -47,10 +47,9 @@ export class JupyterLabAppFactory { } public async createTerminalApp(serverSettings: ServerConnection.ISettings): Promise { - //Need to add this after we remove passing token through url - //const configurationSettings: Partial = serverSettings; - //(configurationSettings.appendToken as boolean) = false; - //serverSettings = ServerConnection.makeSettings(configurationSettings); + const configurationSettings: Partial = serverSettings; + (configurationSettings.appendToken as boolean) = false; + serverSettings = ServerConnection.makeSettings(configurationSettings); const manager = new TerminalManager({ serverSettings: serverSettings, });