Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Speed up interpreter locators #676

Merged

Conversation

DonJayamanne
Copy link

Fixes #666

octref and others added 30 commits November 3, 2017 13:11
* 'master' of https://github.com/Microsoft/vscode-python:
  Fixes #56 list all environments (#219)
  Fixes #57 Disable activation on debugging (#220)
  Fixes #26 Do not run linters when linters are disabled (#222)
* upstream/master:
  Fix typo in README.md (#252)
  Disable linter without workspaces (#241)
* upstream/master:
  Fix feedback service (#246)
  Fix django context initializer (#248)
  disable generation of tags file upon extension load (#264)
* upstream/master:
  Resolve pythonPath before comparing it to shebang (#273)
* upstream/master:
  Fixes #22 to Detect anaconda from known locations  (#221)
  Use workspaceFolder token instead of workspaceRoot (#267)
  Fix registry lookup response (#224)
  Fix issues when running without debugging and debugged code terminates (#249)
* upstream/master:
  Fix debugging tests (#304)
* upstream/master:
  Remove jupyter functionality in favor of Jupyter extension (#302)
  Drop Python 2 URLs (#307)
* upstream/master:
  Remove setting python.formatting.formatOnSave in favor of the vs code setting (#312)
* upstream/master:
  Remove setting linting.lintOnTextChange as it was never implemented (#315)
* upstream/master:
  Fix travis build error (#326)
* upstream/master:
  add new npm deps with improved gulp for dev (#328)
* upstream/master:
  Update version of inversify package (#329)
* upstream/master:
  Document our dev process (#330)
* upstream/master:
  Document contribution to the code along with coding standards (#321)
* upstream/master:
  Add Simplified Chinese translation of commands (#240)
* upstream/master:
  Fix package.json (#347)
* upstream/master:
  #34, #110 - suppress Intellisense in strings and comments (#339)
  Re-factor code python execution framework  (#345)
* upstream/master:
  Fix linters to make use of the new python code execution framework (#360)
  Update the versioning scheme (#356)
  Make npm happy in regards to line endings (#357)
* upstream/master:
  Ensure python path is not set if already set in user settings (#369)
  Use 'an' rather than 'a' before vowel words (#373)
* upstream/master:
  Use new environment variable parser (#362)
* upstream/master:
  Complete refactoring of code to use new code exec engine (#493)
* upstream/master:
  Improve interpreter selection on different platforms (#517)
  Yarn and code coverage (#475)
* upstream/master:
  Remove Homebrew installation  (#537)
  Introduce per user installation of modules and elevated global install as an option (#532)
  Fix spawn args (#489)
* upstream/master:
  Add `pudb` set trace statement to snippets (#370)
* upstream/master:
  Fix auto-indent regex rules (#562)
  Fix linter installation (#557)
  Upload buillds to azure (#534)
  Delete package-lock.json file (#550)
  Fix exception reported in #447 (#536)
* upstream/master:
  Move badges to the official location within package.json (#587)
  Update contributing guide to mention our monthly release cycle (#567)
  Move issue template to the .github directory (#566)
* upstream/master:
  Added unit test attaching a debugger (#597)
  Add delay for exec in terminal (#592)
  Update TPN for opn and arch (#600)
  Clean build output (#595)
  import specific parts of rxjs to speed up loading (#596)
* upstream/master:
  update reflect metadata dependency (#604)
* upstream/master:
  WIP - Activate environment in terminal (#614)
  Add telemetry for debugger (#546)
* upstream/master:
  Implements linting configuration (#599)
* upstream/master:
  Add command to create a python terminal (#625)
  Always display interpreter status bar (#623)
  Do not clear interpreter cache (#621)
* upstream/master:
  Create a release candidate (#663)
  Activation of terminal using conda activate and fixes to powershell script execution (#665)
@codecov
Copy link

codecov bot commented Feb 1, 2018

Codecov Report

Merging #676 into master will increase coverage by 0.08%.
The diff coverage is 85.22%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #676      +/-   ##
==========================================
+ Coverage   61.44%   61.53%   +0.08%     
==========================================
  Files         233      234       +1     
  Lines       10635    10676      +41     
  Branches     1852     1854       +2     
==========================================
+ Hits         6535     6569      +34     
- Misses       4094     4101       +7     
  Partials        6        6
Impacted Files Coverage Δ
src/client/interpreter/contracts.ts 100% <ø> (ø) ⬆️
src/client/common/types.ts 100% <ø> (ø) ⬆️
src/client/interpreter/index.ts 68.23% <0%> (ø) ⬆️
src/client/common/featureDeprecationManager.ts 53.7% <0%> (ø) ⬆️
...t/interpreter/configuration/interpreterSelector.ts 21.21% <0%> (-0.33%) ⬇️
...terpreter/locators/services/condaEnvFileService.ts 92.72% <100%> (+0.41%) ⬆️
...interpreter/locators/services/virtualEnvService.ts 75% <100%> (+1.22%) ⬆️
src/client/interpreter/locators/index.ts 88.37% <100%> (-2.2%) ⬇️
src/client/common/persistentState.ts 85.71% <100%> (ø) ⬆️
...t/interpreter/locators/services/condaEnvService.ts 88.05% <100%> (+0.55%) ⬆️
... and 7 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 d596beb...60e79bc. Read the comment docs.

private getCachedInterpreters() {
const persistentFactory = this.serviceContainer.get<IPersistentStateFactory>(IPersistentStateFactory);
// tslint:disable-next-line:no-any
const globalPersistence = persistentFactory.createGlobalPersistentState<PythonInterpreter[]>(`${this.cacheKey}`, undefined as any);
Copy link
Member

Choose a reason for hiding this comment

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

Why the call use `${this.cacheKey}` instead of just this.cacheKey as a direct argument?

Copy link
Author

Choose a reason for hiding this comment

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

left overs of code refactoring.

Copy link
Author

Choose a reason for hiding this comment

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

Damn another commit, another round of travis tests.

@DonJayamanne DonJayamanne merged commit b09a421 into microsoft:master Feb 1, 2018
@DonJayamanne DonJayamanne deleted the speedUpInterpreterLocators branch February 22, 2018 19:22
@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.

Speed up interpreter selection (with cached & or partial lists)
3 participants