forked from DonJayamanne/pythonVSCode
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypes.ts
More file actions
26 lines (20 loc) · 945 Bytes
/
types.ts
File metadata and controls
26 lines (20 loc) · 945 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { Uri } from 'vscode';
import { ILintingSettings } from '../common/configSettings';
import { ExecutionInfo, Product } from '../common/types';
export interface IErrorHandler {
handleError(error: Error, resource: Uri, execInfo: ExecutionInfo): Promise<boolean>;
}
export const ILinterHelper = Symbol('ILinterHelper');
export type LinterId = 'flake8' | 'mypy' | 'pep8' | 'prospector' | 'pydocstyle' | 'pylama' | 'pylint';
export type LinterSettingsPropertyNames = {
enabledName: keyof ILintingSettings;
argsName: keyof ILintingSettings;
pathName: keyof ILintingSettings;
};
export interface ILinterHelper {
getExecutionInfo(linter: Product, customArgs: string[], resource?: Uri): ExecutionInfo;
translateToId(linter: Product): LinterId;
getSettingsPropertyNames(linter: Product): LinterSettingsPropertyNames;
}