Skip to content

Warn on TSServer Plugin Contributions from other extensions#4063

Open
DanielRosenwasser wants to merge 11 commits into
mainfrom
warnOnPlugins
Open

Warn on TSServer Plugin Contributions from other extensions#4063
DanielRosenwasser wants to merge 11 commits into
mainfrom
warnOnPlugins

Conversation

@DanielRosenwasser
Copy link
Copy Markdown
Member

(Builds on #4052)

Fixes #3848.

@DanielRosenwasser DanielRosenwasser changed the title Warn on plugins Warn on TSServer Plugin Contributios from other extensions May 27, 2026
@DanielRosenwasser DanielRosenwasser marked this pull request as ready for review May 27, 2026 19:45
Copilot AI review requested due to automatic review settings May 27, 2026 19:45
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 3/3 changed files
  • Comments generated: 5

Comment thread _extension/src/extension.ts Outdated
const settingName = getWinningTsgoConfigKey()!;
assert(settingName !== undefined, "Expected some useTsgo configuration to be explicitly set.");

const target = getExplicitConfigTarget(vscode.workspace.getConfiguration(), settingName);
Comment thread _extension/src/extension.ts Outdated
Comment on lines +130 to +132
warnAboutTsServerPlugins(context, output);
context.subscriptions.push(vscode.extensions.onDidChange(() => {
warnAboutTsServerPlugins(context, output);
Comment thread _extension/src/extension.ts Outdated
Comment on lines +220 to +230
const ok = "OK";
const disableInWorkspace = "Disable in Workspace";
const dontShowAgain = hasWorkspaceFolder ? "Don't Show Again in Workspace" : "Don't Show Again";

const options = [ok];
if (hasWorkspaceFolder) {
options.push(disableInWorkspace);
}
options.push(dontShowAgain);

const selected = await vscode.window.showWarningMessage(message, ...options);
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should just have some state so we don't show it more than once per session.

Comment thread _extension/src/extension.ts Outdated
@DanielRosenwasser DanielRosenwasser changed the title Warn on TSServer Plugin Contributios from other extensions Warn on TSServer Plugin Contributions from other extensions May 27, 2026
@RyanCavanaugh RyanCavanaugh added this to the TypeScript 7.0 RC milestone May 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Issue warning when extensions try to contribute TSServer plugins that while useTsgo is on

3 participants