Skip to content

PTVS engine update + handling of the interpreter change#1613

Merged
MikhailArkhipov merged 71 commits intomicrosoft:masterfrom
MikhailArkhipov:analysis
May 9, 2018
Merged

PTVS engine update + handling of the interpreter change#1613
MikhailArkhipov merged 71 commits intomicrosoft:masterfrom
MikhailArkhipov:analysis

Conversation

@MikhailArkhipov
Copy link
Copy Markdown

  • Update test baselines to reflect changes in VS engine
  • Add handling of interpreter change in the language client

(Multiroot WS issue is still open in #1149)

This pull request:

  • Has a title summarizes what is changing
  • Has unit tests & code coverage is not adversely affected (within reason)
  • Works on all actively maintained versions of Python (e.g. Python 2.7 & the latest Python 3 release)
  • Works on Windows 10, macOS, and Linux (e.g. considered file system case-sensitivity)


if (downloadPackage) {
const downloader = new AnalysisEngineDownloader(this.services, analysisEngineFolder);
this.appShell.showWarningMessage('.NET Runtime is not found, platform-specific Python Analysis Engine will be downloaded.');
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 this be an information message, instead of a warning?

}

// tslint:disable-next-line:no-string-literal
properties['DatabasePath'] = path.join(context.extensionPath, analysisEngineFolder);
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

No need to change, but you can avoid the linter messages if you define properties as follows:
const properties: {[key: string]:string} = {};

this.output.append(`Downloading ${uri}... `);
const tempFile = await createTemporaryFile(downloadFileExtension);

const deferred = createDeferred();
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This deferred is not used

});
}

public copyFileAsync(src: string, dest: string): Promise<void> {
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Please remove Async suffix.

return deferred.promise;
}

public deleteFileAsync(filename: string): Promise<void> {
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Please remove Async suffix.

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.

Should we remove them all from IFileSystem? Currently we [sort of] follow node's 'fs' which has plain and Sync

Comment thread src/client/common/platform/types.ts Outdated
// tslint:disable-next-line:unified-signatures
appendFileSync(filename: string, data: {}, options?: { encoding?: string; mode?: string; flag?: string }): void;
getRealPathAsync(path: string): Promise<string>;
copyFileAsync(src: string, dest: string): Promise<void>;
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Please remove Async suffix.

Comment thread news/2 Fixes/1354.md Outdated
@@ -0,0 +1 @@
Multiple fixes to format on type No newline at end of file
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

I can't see any fixes for format on type or am I missing something.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 5, 2018

Codecov Report

Merging #1613 into master will decrease coverage by 0.36%.
The diff coverage is 5.05%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1613      +/-   ##
==========================================
- Coverage   71.62%   71.25%   -0.37%     
==========================================
  Files         277      273       -4     
  Lines       12816    12759      -57     
  Branches     2299     2293       -6     
==========================================
- Hits         9179     9092      -87     
- Misses       3502     3526      +24     
- Partials      135      141       +6
Impacted Files Coverage Δ
src/client/common/platform/types.ts 100% <ø> (ø) ⬆️
src/client/common/types.ts 100% <ø> (ø) ⬆️
src/client/activation/interpreterDataService.ts 12.08% <0%> (ø) ⬆️
src/client/activation/hashVerifier.ts 23.52% <0%> (ø) ⬆️
src/client/activation/analysis.ts 14.18% <2.77%> (-2.21%) ⬇️
src/client/activation/downloader.ts 17.14% <5.71%> (-3.32%) ⬇️
src/client/common/configSettings.ts 87.71% <50%> (-0.24%) ⬇️
src/client/common/platform/fileSystem.ts 62.9% <7.14%> (-16.27%) ⬇️
src/client/debugger/PythonProcess.ts 45.83% <0%> (-5.42%) ⬇️
src/client/common/process/pythonToolService.ts 66.66% <0%> (-4.77%) ⬇️
... and 33 more

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 128d231...cf5cf9c. Read the comment docs.

@MikhailArkhipov MikhailArkhipov merged commit f18a5ee into microsoft:master May 9, 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.

3 participants