Skip to content

Commit f0691a7

Browse files
authored
Instead of showing interpreter path, show session path for existing kernels. (#11152)
1 parent eab579f commit f0691a7

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

news/2 Fixes/10521.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Show notebook path when listing remote kernels.

src/client/datascience/jupyter/kernels/kernelSelections.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ function getQuickPickItemForActiveKernel(kernel: LiveKernelModel, pathUtils: IPa
4545
const path = kernel.metadata?.interpreter?.path || kernel.path;
4646
return {
4747
label: kernel.display_name || kernel.name || '',
48-
// If we have a matching interpreter, then display that path in the dropdown else path of the kernelspec.
49-
detail: path ? pathUtils.getDisplayName(path) : '',
48+
// If we have a session, use that path
49+
detail: kernel.session.path || !path ? kernel.session.path : pathUtils.getDisplayName(path),
5050
description: localize.DataScience.jupyterSelectURIRunningDetailFormat().format(
5151
kernel.lastActivityTime.toLocaleString(),
5252
kernel.numberOfConnections.toString()

0 commit comments

Comments
 (0)