From 10f1afbb46ac3f55ad602bb78fabfa44dba97052 Mon Sep 17 00:00:00 2001 From: Dhruvi Sompura Date: Thu, 19 Dec 2024 16:25:29 -0800 Subject: [PATCH] Make output channel names consistent (#5833) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ### Description Addresses #1707 @:output We've received feedback that the output channel list is confusing and not easy to parse. A lot of the channel names are prefixed with "Positron" which is redundant. The formatting of the names for the language channels is not consistent and adds friction to the UX when scanning the list. The proposed change here does some tidying 🧹 of the names to improve the UX: * The "Positron" prefix has been removed * The language specific channel names have a consistent formatting which groups them together in the select * Updates ambiguous output channel names ### Screenshots Screenshot 2024-12-19 at 10 20 58 AM Screenshot 2024-12-19 at 10 25 38 AM --- extensions/positron-code-cells/src/logging.ts | 2 +- extensions/positron-notebook-controllers/src/extension.ts | 2 +- extensions/positron-proxy/src/extension.ts | 2 +- .../positron-python/src/client/common/utils/localize.ts | 4 +++- .../src/client/positron/lspOutputChannelManager.ts | 6 ++++-- extensions/positron-r/src/extension.ts | 2 +- extensions/positron-r/src/lsp-output-channel-manager.ts | 4 ++-- extensions/positron-run-app/src/extension.ts | 2 +- extensions/positron-supervisor/src/extension.ts | 2 +- 9 files changed, 15 insertions(+), 11 deletions(-) diff --git a/extensions/positron-code-cells/src/logging.ts b/extensions/positron-code-cells/src/logging.ts index a1f125f846e..18c30bca8d1 100644 --- a/extensions/positron-code-cells/src/logging.ts +++ b/extensions/positron-code-cells/src/logging.ts @@ -7,7 +7,7 @@ import * as vscode from 'vscode'; let channel: vscode.OutputChannel | undefined; export function initializeLogging() { - channel = vscode.window.createOutputChannel('Positron Code Cells'); + channel = vscode.window.createOutputChannel('Code Cells'); } export function trace(message: string) { diff --git a/extensions/positron-notebook-controllers/src/extension.ts b/extensions/positron-notebook-controllers/src/extension.ts index 491c60ed563..cacfb22e9ab 100644 --- a/extensions/positron-notebook-controllers/src/extension.ts +++ b/extensions/positron-notebook-controllers/src/extension.ts @@ -12,7 +12,7 @@ import { JUPYTER_NOTEBOOK_TYPE } from './constants'; import { registerExecutionInfoStatusBar } from './statusBar'; import { getNotebookSession, isActiveNotebookEditorUri } from './utils'; -export const log = vscode.window.createOutputChannel('Positron Notebook Controllers', { log: true }); +export const log = vscode.window.createOutputChannel('Notebook Controllers', { log: true }); const _onDidSetHasRunningNotebookSessionContext = new vscode.EventEmitter(); diff --git a/extensions/positron-proxy/src/extension.ts b/extensions/positron-proxy/src/extension.ts index fc906ef37ff..285b30bfd27 100644 --- a/extensions/positron-proxy/src/extension.ts +++ b/extensions/positron-proxy/src/extension.ts @@ -15,7 +15,7 @@ export type ProxyServerStyles = { readonly [key: string]: string | number }; /** * Positron Proxy log output channel. */ -export const log = vscode.window.createOutputChannel('Positron Proxy', { log: true }); +export const log = vscode.window.createOutputChannel('HTML Proxy Server', { log: true }); /** * Activates the extension. diff --git a/extensions/positron-python/src/client/common/utils/localize.ts b/extensions/positron-python/src/client/common/utils/localize.ts index 09b966a22c4..70b5cf65884 100644 --- a/extensions/positron-python/src/client/common/utils/localize.ts +++ b/extensions/positron-python/src/client/common/utils/localize.ts @@ -266,7 +266,9 @@ export namespace InterpreterQuickPickList { export namespace OutputChannelNames { export const languageServer = l10n.t('Python Language Server'); - export const python = l10n.t('Python'); + // --- Start Positron --- + export const python = l10n.t('Python Language Pack'); + // --- End Positron --- export const pythonTest = l10n.t('Python Test Log'); } diff --git a/extensions/positron-python/src/client/positron/lspOutputChannelManager.ts b/extensions/positron-python/src/client/positron/lspOutputChannelManager.ts index a68548f4232..8c12a20ae17 100644 --- a/extensions/positron-python/src/client/positron/lspOutputChannelManager.ts +++ b/extensions/positron-python/src/client/positron/lspOutputChannelManager.ts @@ -5,7 +5,7 @@ import * as vscode from 'vscode'; -const LSP_OUTPUT_CHANNEL_PREFIX = 'Positron Language Server: '; +const LSP_OUTPUT_CHANNEL_DESCRIPTOR = 'Language Server'; /** * Manages all the Python LSP output channels @@ -47,7 +47,9 @@ export class PythonLspOutputChannelManager { let out = this._channels.get(key); if (!out) { - const name = `${LSP_OUTPUT_CHANNEL_PREFIX}${sessionName} (${sessionMode})`; + const name = `${sessionName}: ${LSP_OUTPUT_CHANNEL_DESCRIPTOR} (${ + sessionMode.charAt(0).toUpperCase() + sessionMode.slice(1) + })`; out = vscode.window.createOutputChannel(name); this._channels.set(key, out); } diff --git a/extensions/positron-r/src/extension.ts b/extensions/positron-r/src/extension.ts index 26963c07caf..52c4d6e6276 100644 --- a/extensions/positron-r/src/extension.ts +++ b/extensions/positron-r/src/extension.ts @@ -14,7 +14,7 @@ import { setupTestExplorer, refreshTestExplorer } from './testing/testing'; import { RRuntimeManager } from './runtime-manager'; import { registerUriHandler } from './uri-handler'; -export const LOGGER = vscode.window.createOutputChannel('Positron R Extension', { log: true }); +export const LOGGER = vscode.window.createOutputChannel('R Language Pack', { log: true }); export function activate(context: vscode.ExtensionContext) { const onDidChangeLogLevel = (logLevel: vscode.LogLevel) => { diff --git a/extensions/positron-r/src/lsp-output-channel-manager.ts b/extensions/positron-r/src/lsp-output-channel-manager.ts index 5a6656b89d4..82bdd9e2bf1 100644 --- a/extensions/positron-r/src/lsp-output-channel-manager.ts +++ b/extensions/positron-r/src/lsp-output-channel-manager.ts @@ -5,7 +5,7 @@ import * as vscode from 'vscode'; -const LSP_OUTPUT_CHANNEL_PREFIX = 'Positron Language Server: '; +const LSP_OUTPUT_CHANNEL_DESCRIPTOR = 'Language Server'; /** * Manages all the R LSP output channels @@ -47,7 +47,7 @@ export class RLspOutputChannelManager { let out = this._channels.get(key); if (!out) { - const name = `${LSP_OUTPUT_CHANNEL_PREFIX}${sessionName} (${sessionMode})`; + const name = `${sessionName}: ${LSP_OUTPUT_CHANNEL_DESCRIPTOR} (${sessionMode.charAt(0).toUpperCase() + sessionMode.slice(1)})`; out = vscode.window.createOutputChannel(name); this._channels.set(key, out); } diff --git a/extensions/positron-run-app/src/extension.ts b/extensions/positron-run-app/src/extension.ts index d5fc433494a..abbf01683bd 100644 --- a/extensions/positron-run-app/src/extension.ts +++ b/extensions/positron-run-app/src/extension.ts @@ -8,7 +8,7 @@ import { PositronRunAppApiImpl } from './api'; import { registerDebugAdapterTrackerFactory } from './debugAdapterTrackerFactory'; import { PositronRunApp } from './positron-run-app'; -export const log = vscode.window.createOutputChannel('Positron Run App', { log: true }); +export const log = vscode.window.createOutputChannel('App Launcher', { log: true }); export enum Config { ShellIntegrationEnabled = 'terminal.integrated.shellIntegration.enabled', diff --git a/extensions/positron-supervisor/src/extension.ts b/extensions/positron-supervisor/src/extension.ts index ef81eacff73..2116f7c904e 100644 --- a/extensions/positron-supervisor/src/extension.ts +++ b/extensions/positron-supervisor/src/extension.ts @@ -13,7 +13,7 @@ import { KCApi } from './KallichoreAdapterApi'; export let API_INSTANCE: KCApi; export function activate(context: vscode.ExtensionContext): KallichoreAdapterApi { - const log = positron.window.createRawLogOutputChannel('Positron Kernel Supervisor'); + const log = positron.window.createRawLogOutputChannel('Kernel Supervisor'); log.appendLine('Positron Kernel Supervisor activated'); // Create the singleton instance of the Kallichore API wrapper