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

Remote Explorer views are not getting removed when a profile is deleted #186290

Closed
bpasero opened this issue Jun 27, 2023 · 5 comments · Fixed by #186512
Closed

Remote Explorer views are not getting removed when a profile is deleted #186290

bpasero opened this issue Jun 27, 2023 · 5 comments · Fixed by #186512
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders user-profiles User profile management verified Verification succeeded
Milestone

Comments

@bpasero
Copy link
Member

bpasero commented Jun 27, 2023

I had a "Testing" profile with various remote extensions installed. I deleted it (while being in it) and then recreated it empty. I still found all remote menu contributions even though the profile should have been empty.

Maybe switching profiles should ask to reload the window when extensions require so?

Steps to Reproduce:

  • fresh user data dir, fresh extensions dir
  • create an empty profile
  • install SSH extension
  • notice how the remote explorer view appears
  • delete the profile
  • notice how the remote explorer view is still there, same as the status bar entry for remote
@bpasero bpasero changed the title Extensions that require reload on uninstall should ask user to reload Extensions that require reload on uninstall / disablement should ask user to reload Jun 27, 2023
@bpasero
Copy link
Member Author

bpasero commented Jun 27, 2023

Another case from #186315 is interesting: I do not think using a profile is a good idea for when extensions require a window reload to be disabled. So you need to then probably ask the user to reload the window or do it automatically.

@jrieken
Copy link
Member

jrieken commented Jun 28, 2023

idea for when extensions require a window reload to be disabled.

AFAIK every extension requires a window reload after being disabled (except for package-json only extensions). We cannot unload code from extensions and cannot enforce them not doing anything anymore. There we always reload the window or at least the extension host

@sandy081
Copy link
Member

sandy081 commented Jun 28, 2023

@bpasero While switching profiles we restart extension host. You say this is not enough to unload extensions?
Also while trusting/untrusting a workspace.

@bpasero
Copy link
Member Author

bpasero commented Jun 28, 2023

@jrieken

AFAIK every extension requires a window reload after being disabled

No, only those that are activate with code loaded.

@sandy081

While switching profiles we restart extension host. You say this is not enough to unload extensions

Here are steps:

  • fresh user data dir, fresh extensions dir
  • create an empty profile
  • install SSH extension
  • notice how the remote explorer view appears
  • delete the profile
  • notice how the remote explorer view is still there, same as the status bar entry for remote

@sandy081
Copy link
Member

@bpasero I see this can be reproduced with above steps. But Remote Explorer view disappears with switching profile. So I think this is a bug (either in views or profiles) when profile is deleted. But status bar entries always appear.

@sandy081 sandy081 changed the title Extensions that require reload on uninstall / disablement should ask user to reload Remote Explorer views are not getting removed when a profile is deleted Jun 28, 2023
@sandy081 sandy081 added bug Issue identified by VS Code Team member as probable bug user-profiles User profile management labels Jun 28, 2023
@sandy081 sandy081 added this to the June 2023 milestone Jun 28, 2023
sandy081 added a commit that referenced this issue Jun 28, 2023
sandy081 added a commit that referenced this issue Jun 28, 2023
@VSCodeTriageBot VSCodeTriageBot added unreleased Patch has not yet been released in VS Code Insiders insiders-released Patch has been released in VS Code Insiders and removed unreleased Patch has not yet been released in VS Code Insiders labels Jun 28, 2023
@bhavyaus bhavyaus added the verified Verification succeeded label Jun 29, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Aug 12, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders user-profiles User profile management verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants