Skip to content

Use the autoStart server if it matches when starting a new server #9929

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

Merged

Conversation

IanMatthewHuff
Copy link
Member

For #9926

  • Pull request represents a single change (i.e. not fixing disparate/unrelated things in a single PR).
  • Title summarizes what is changing.
  • Has a news entry file (remember to thank yourself!).
  • Appropriate comments and documentation strings in the code.
  • Has sufficient logging.
  • Has telemetry for enhancements.
  • Unit tests & system/integration tests are added/updated.
  • Test plan is updated as appropriate.
  • package-lock.json has been regenerated by running npm install (if dependencies have changed).
  • The wiki is updated with any design decisions/details.

@@ -43,7 +44,7 @@ export class ServerCache implements IAsyncDisposable {

// See if the old options had the same UI setting. If not,
// cancel the old
if (data && data.options.disableUI !== fixedOptions.disableUI) {
Copy link
Member Author

Choose a reason for hiding this comment

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

the autostart server always has disableUI set to true.

@@ -75,6 +77,12 @@ export class ServerCache implements IAsyncDisposable {
return oldDispose();
};

// We've resolved the promise at this point
const resolvedData = this.cache.get(key);
Copy link

Choose a reason for hiding this comment

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

I don't think you need to get it from the cache again. The local variable 'data' should work too, no?

Copy link
Member Author

Choose a reason for hiding this comment

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

Hmm, you know, looking at it, it should be there. I was debugging and didn't have "data" available in the debug console. Lemme try it quick and see.

Copy link
Member Author

Choose a reason for hiding this comment

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

@rchiodo right you are. changing quick. Wonder why the debugger didn't see it?

Copy link

Choose a reason for hiding this comment

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

Who knows. It can be pretty flakey with data on the stack.


In reply to: 375531583 [](ancestors = 375531583)

Copy link

Choose a reason for hiding this comment

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

Might be in one of the other 'closure' entries.


In reply to: 375531898 [](ancestors = 375531898,375531583)

Copy link

@rchiodo rchiodo left a comment

Choose a reason for hiding this comment

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

:shipit:

@sonarqubecloud
Copy link

sonarqubecloud bot commented Feb 5, 2020

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@codecov-io
Copy link

codecov-io commented Feb 5, 2020

Codecov Report

Merging #9929 into master will decrease coverage by <.01%.
The diff coverage is 66.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #9929      +/-   ##
==========================================
- Coverage   61.22%   61.21%   -0.01%     
==========================================
  Files         563      564       +1     
  Lines       30058    30063       +5     
  Branches     4545     4546       +1     
==========================================
+ Hits        18403    18404       +1     
- Misses      10626    10629       +3     
- Partials     1029     1030       +1
Impacted Files Coverage Δ
...lient/datascience/jupyter/liveshare/serverCache.ts 65.33% <66.66%> (-0.43%) ⬇️
...atascience-ui/data-explorer/globalJQueryImports.ts 0% <0%> (ø)

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 812e98b...9a661b1. Read the comment docs.

@IanMatthewHuff IanMatthewHuff merged commit 4458703 into microsoft:master Feb 5, 2020
@IanMatthewHuff IanMatthewHuff deleted the dev/ianhu/fixServerCache branch February 5, 2020 22:58
IanMatthewHuff added a commit to IanMatthewHuff/vscode-python that referenced this pull request Feb 5, 2020
…crosoft#9929)

* don't cancel an already resolve servercache just due to disableUI changes

* don't pull data a second time
@lock lock bot locked as resolved and limited conversation to collaborators Feb 12, 2020
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