Skip to content

Only force background envs refresh if the component is enabled.#15132

Merged
ericsnowcurrently merged 3 commits intomicrosoft:mainfrom
ericsnowcurrently:pyenvs-component-activate-if-in-experiment
Feb 2, 2021
Merged

Only force background envs refresh if the component is enabled.#15132
ericsnowcurrently merged 3 commits intomicrosoft:mainfrom
ericsnowcurrently:pyenvs-component-activate-if-in-experiment

Conversation

@ericsnowcurrently
Copy link
Copy Markdown

@ericsnowcurrently ericsnowcurrently commented Jan 12, 2021

(for #14984)

This ensures that the component is not used at all if not in the relevant experiments.

(FYI, this is a branch I had lying around so I figured I'd move it along.)

  • Pull request represents a single change (i.e. not fixing disparate/unrelated things in a single PR).
  • Title summarizes what is changing.
  • Appropriate comments and documentation strings in the code.
  • [ ] Has sufficient logging.
  • [ ] Has telemetry for enhancements.
  • [ ] The wiki is updated with any design decisions/details.

@@ -59,10 +59,12 @@ export function initialize(ext: ExtensionState): PythonEnvironments {
* Make use of the component (e.g. register with VS Code).
*/
export async function activate(api: PythonEnvironments): Promise<ActivationResult> {
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

activate() is never called, so I don't think this'll have any effect.

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.

Yeah, I forgot to fix that. It's fixed now.

@karrtikr karrtikr added the skip tests Updates to tests unnecessary label Jan 13, 2021
@ericsnowcurrently ericsnowcurrently force-pushed the pyenvs-component-activate-if-in-experiment branch from 181327e to c45cd3a Compare February 2, 2021 17:16
@ericsnowcurrently ericsnowcurrently merged commit 778ca97 into microsoft:main Feb 2, 2021
@ericsnowcurrently ericsnowcurrently deleted the pyenvs-component-activate-if-in-experiment branch February 2, 2021 17:44
@karrtikr
Copy link
Copy Markdown

With this PR we're activating the discovery component before we have registered all the things to be used for the component. Few of the bugs we discovered in bugbash are because of this #15310 #15355 #15361

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-changelog No news entry required skip tests Updates to tests unnecessary

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants