Skip to content

Change how we offer to install/disable linters - #973

Merged
Mikhail Arkhipov (MikhailArkhipov) merged 122 commits into
microsoft:masterfrom
MikhailArkhipov:master
Mar 7, 2018
Merged

Mikhail Arkhipov (MikhailArkhipov) merged 122 commits into
microsoft:masterfrom
MikhailArkhipov:master

Conversation

@MikhailArkhipov

@MikhailArkhipov Mikhail Arkhipov (MikhailArkhipov) commented Mar 7, 2018 •

Copy link
Copy Markdown

Fixes #971

  • Remove confusing 'disable for a session' flag
  • Explicitly offer
    a. Install linter
    b. Disable this linter
    c. Disable all linters

Close button does nothing

image

@codecov

codecov Bot commented Mar 7, 2018 •

Copy link
Copy Markdown

Codecov Report

Merging #973 into master will increase coverage by 0.25%.
The diff coverage is 40%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #973      +/-   ##
==========================================
+ Coverage   64.01%   64.27%   +0.25%     
==========================================
  Files         260      260              
  Lines       12027    12022       -5     
  Branches     2130     2129       -1     
==========================================
+ Hits         7699     7727      +28     
+ Misses       4319     4286      -33     
  Partials        9        9
Impacted Files Coverage Δ
src/client/linters/types.ts 100% <ø> (ø) ⬆️
src/client/linters/linterManager.ts 82.6% <ø> (+2.34%) ⬆️
src/client/common/installer/productInstaller.ts 66.66% <40%> (+3.62%) ⬆️
src/client/linters/baseLinter.ts 91.66% <0%> (+6.25%) ⬆️
src/client/common/application/applicationShell.ts 30.76% <0%> (+7.69%) ⬆️
src/client/common/logger.ts 53.33% <0%> (+20%) ⬆️
src/client/linters/errorHandlers/errorHandler.ts 100% <0%> (+22.22%) ⬆️
src/client/linters/errorHandlers/notInstalled.ts 94.44% <0%> (+61.11%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 23b9c38...27fced6. Read the comment docs.

const lm = this.serviceContainer.get<ILinterManager>(ILinterManager);
if (response === disable) {
if (response === disableAllLinting) {
await lm.enableLintingAsync(false);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Shouldn't the return value from here be InstallerResponse.Disabled?

} else {
lm.disableSessionLinting();
} else if (response === disableThisLinter) {
await lm.getLinterInfo(product).enableAsync(false);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Shouldn't the return value from here be InstallerResponse.Disabled?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Good idea. Will do.

MikhailArkhipov added 3 commits March 7, 2018 10:54
@MikhailArkhipov
Mikhail Arkhipov (MikhailArkhipov) merged commit 563f11d into microsoft:master Mar 7, 2018
@lock lock Bot locked as resolved and limited conversation to collaborators Jul 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Multiple linters not working in VS Code

3 participants