Skip to content

Commit b0e80c8

Browse files
authored
Remove unused localized strings (microsoft#17486)
* Remove strings unused in the code * Remove extra .ropeproject
1 parent 8572b3b commit b0e80c8

7 files changed

Lines changed: 0 additions & 173 deletions

File tree

package.nls.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,12 +93,8 @@
9393
"ExtensionChannels.downloadCompletedOutputMessage": "Insiders build download complete.",
9494
"ExtensionChannels.startingDownloadOutputMessage": "Starting download for Insiders build.",
9595
"Interpreters.environmentPromptMessage": "We noticed a new virtual environment has been created. Do you want to select it for the workspace folder?",
96-
"Linter.enableLinter": "Enable {0}",
97-
"Linter.enablePylint": "You have a pylintrc file in your workspace. Do you want to enable pylint?",
9896
"Linter.replaceWithSelectedLinter": "Multiple linters are enabled in settings. Replace with '{0}'?",
9997
"Linter.install": "Install a linter to get error reporting.",
100-
"Linter.installPylint": "Install pylint",
101-
"Linter.installFlake8": "Install flake8",
10298
"Linter.selectLinter": "Select Linter",
10399
"Installer.noCondaOrPipInstaller": "There is no Conda or Pip installer available in the selected environment.",
104100
"Installer.noPipInstaller": "There is no Pip installer available in the selected environment.",

package.nls.zh-cn.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,12 +90,8 @@
9090
"ExtensionChannels.downloadCompletedOutputMessage": "预览版下载完成。",
9191
"ExtensionChannels.startingDownloadOutputMessage": "开始下载预览版。",
9292
"Interpreters.environmentPromptMessage": "检测到新的虚拟环境,是否在此工作区中使用它?",
93-
"Linter.enableLinter": "启用 {0}",
94-
"Linter.enablePylint": "该工作区有一个 pylintrc 文件,是否启用 pylint?",
9593
"Linter.replaceWithSelectedLinter": "设置中启用了多个代码检查器,是否用 '{0}' 替换?",
9694
"Linter.install": "请安装一个代码检查器以获得错误报告。",
97-
"Linter.installPylint": "安装 pylint",
98-
"Linter.installFlake8": "安装 flake8",
9995
"Linter.selectLinter": "选择代码检查器",
10096
"Installer.noCondaOrPipInstaller": "所选环境中没有可用的 Conda 或 pip 安装器。",
10197
"Installer.noPipInstaller": "所选环境中没有可用的 pip 安装器。",

package.nls.zh-tw.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,6 @@
5454
"ExtensionChannels.downloadCompletedOutputMessage": "Insiders 組建下載完成。",
5555
"ExtensionChannels.startingDownloadOutputMessage": "開始下載 Insiders 組建。",
5656
"Interpreters.environmentPromptMessage": "We noticed a new virtual environment has been created. Do you want to select it for the workspace folder?",
57-
"Linter.enableLinter": "啟用 {0}",
58-
"Linter.enablePylint": "您的工作區有 pylintrc 檔案。是否啟用 pylint?",
5957
"Linter.replaceWithSelectedLinter": "設定中啟用了多個 Linter。是否用 '{0}' 取代?",
6058
"Installer.noCondaOrPipInstaller": "選取環境中沒有可用的 Conda 或 Pip 安裝工具。",
6159
"Installer.noPipInstaller": "選取環境中沒有可用的 Pip 安裝工具。",

pythonFiles/.vscode/.ropeproject/config.py

Lines changed: 0 additions & 114 deletions
This file was deleted.
-6 Bytes
Binary file not shown.

src/client/common/utils/localize.ts

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -352,19 +352,10 @@ export namespace Logging {
352352
}
353353

354354
export namespace Linters {
355-
export const enableLinter = localize('Linter.enableLinter', 'Enable {0}');
356-
export const enablePylint = localize(
357-
'Linter.enablePylint',
358-
'You have a pylintrc file in your workspace. Do you want to enable pylint?',
359-
);
360355
export const replaceWithSelectedLinter = localize(
361356
'Linter.replaceWithSelectedLinter',
362357
"Multiple linters are enabled in settings. Replace with '{0}'?",
363358
);
364-
365-
export const installMessage = localize('Linter.install', 'Install a linter to get error reporting.');
366-
export const installPylint = localize('Linter.installPylint', 'Install pylint');
367-
export const installFlake8 = localize('Linter.installFlake8', 'Install flake8');
368359
export const selectLinter = localize('Linter.selectLinter', 'Select Linter');
369360
}
370361

src/test/common/installer/installer.unit.test.ts

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -51,15 +51,13 @@ import {
5151
} from '../../../client/common/types';
5252
import { createDeferred, Deferred } from '../../../client/common/utils/async';
5353
import { getNamesAndValues } from '../../../client/common/utils/enum';
54-
import { Common, Linters } from '../../../client/common/utils/localize';
5554
import { IInterpreterService } from '../../../client/interpreter/contracts';
5655
import { ServiceContainer } from '../../../client/ioc/container';
5756
import { IServiceContainer } from '../../../client/ioc/types';
5857
import { LinterManager } from '../../../client/linters/linterManager';
5958
import { ILinterManager } from '../../../client/linters/types';
6059
import { PythonEnvironment } from '../../../client/pythonEnvironments/info';
6160
import { sleep } from '../../common';
62-
import { MockWorkspaceConfiguration } from '../../mocks/mockWorkspaceConfig';
6361

6462
use(chaiAsPromised);
6563

@@ -912,43 +910,5 @@ suite('Module Installer only', () => {
912910
expect(response).to.be.equal(InstallerResponse.Installed);
913911
assert.ok(install.calledOnceWith(product, resource, undefined));
914912
});
915-
916-
test('Do not show prompt if linter path is set', async () => {
917-
when(workspaceService.getConfiguration('python')).thenReturn(
918-
new MockWorkspaceConfiguration({
919-
'linting.pylintPath': {
920-
globalValue: 'path/to/something',
921-
},
922-
}),
923-
);
924-
when(productService.getProductType(Product.pylint)).thenReturn(ProductType.Linter);
925-
when(productPathService.getExecutableNameFromSettings(Product.pylint, resource)).thenReturn(
926-
'path/to/something',
927-
);
928-
installer.isModuleExecutable = false;
929-
930-
const product = Product.pylint;
931-
const options = ['Select Linter', 'Do not show again'];
932-
const productName = ProductNames.get(product)!;
933-
await installer.promptToInstallImplementation(product, resource);
934-
verify(
935-
appShell.showInformationMessage(
936-
Linters.installMessage(),
937-
Linters.installPylint(),
938-
Linters.installFlake8(),
939-
Common.doNotShowAgain(),
940-
),
941-
).never();
942-
verify(
943-
appShell.showErrorMessage(`Linter ${productName} is not installed.`, 'Install', options[0], options[1]),
944-
).never();
945-
verify(
946-
appShell.showErrorMessage(
947-
`Path to the ${productName} linter is invalid (path/to/something)`,
948-
options[0],
949-
options[1],
950-
),
951-
).once();
952-
});
953913
});
954914
});

0 commit comments

Comments
 (0)