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

Just restart EH automatically on extension update? #214424

Closed
isidorn opened this issue Jun 6, 2024 · 13 comments
Closed

Just restart EH automatically on extension update? #214424

isidorn opened this issue Jun 6, 2024 · 13 comments
Assignees
Labels
author-verification-requested Issues potentially verifiable by issue author extensions Issues concerning extensions feature-request Request for new features or functionality insiders-released Patch has been released in VS Code Insiders verification-needed Verification of issue is requested verified Verification succeeded
Milestone

Comments

@isidorn
Copy link
Contributor

isidorn commented Jun 6, 2024

I love the new feature that extension updates do not require the whole window reload.
But right now it still requires an action from me to click on "Restart Extensions".

Can you remind me why don't we just restart the EH automatically on extension update? Are we afraid that we might break some other extension?
Can we do some detection to see if it is "safe" to restart automatically? Or can we do some heuristic - if user is not active in VS Code for 5mins we just do it?

The downside of the current approach is that it requires manual restart, and clicking on that button does not give any positive UI feedback (it feels like a no-op).

Image

Also heard this feedback from @chrisdias

@isidorn isidorn added the extensions Issues concerning extensions label Jun 6, 2024
@bpasero
Copy link
Member

bpasero commented Jun 6, 2024

At least for notebooks, the restart might be bumpy for dirty notebooks. Before we do this we should consult with stakeholders of the event we added to participate in restart.

@sandy081 sandy081 added the polish Cleanup and polish issue label Jun 12, 2024
@sandy081 sandy081 added this to the June 2024 milestone Jun 12, 2024
@sandy081
Copy link
Member

I would not restart extensions automatically because this can be disruptive

  • there can be veto dialogs from participants
  • there can be UI flickering - status items or other UI elements reappear.

Being said that, I liked Isi's idea to restart extensions automatically when a window is not in focus. Even there, I would like to restart only if no ext host restart participants has objections.

@sandy081 sandy081 added feature-request Request for new features or functionality and removed polish Cleanup and polish issue labels Jun 12, 2024
@isidorn
Copy link
Contributor Author

isidorn commented Jun 12, 2024

That's a great start!

sandy081 added a commit that referenced this issue Jun 12, 2024
@sandy081
Copy link
Member

  • Added a setting to auto restart extensions following updates when window is not focused. This is enabled by default in insiders.
  • Changed Debug behavior to always veto if there are active sessions. I believe debug should show a veto dialog instead of silently stopping the sessions
  • Added auto parameter to not to show veto dialog if restarting extensions is an automatic operation.

@isidorn
Copy link
Contributor Author

isidorn commented Jun 13, 2024

Awesome, thanks a lot!
Will let you know how it feels in practice!

@VSCodeTriageBot VSCodeTriageBot added the unreleased Patch has not yet been released in VS Code Insiders label Jun 13, 2024
@VSCodeTriageBot VSCodeTriageBot added 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 14, 2024
@kodmanyagha
Copy link

This is so great info. Thanks for this. When you release this feature?

@sandy081 sandy081 added the author-verification-requested Issues potentially verifiable by issue author label Jun 24, 2024
@VSCodeTriageBot
Copy link
Collaborator

This bug has been fixed in the latest release of VS Code Insiders!

@isidorn, you can help us out by commenting /verified if things are now working as expected.

If things still don't seem right, please ensure you're on version 524d1ec of Insiders (today's or later - you can use Help: About in the command palette to check), and leave a comment letting us know what isn't working as expected.

Happy Coding!

@isidorn
Copy link
Contributor Author

isidorn commented Jun 24, 2024

@sandy081 I tried verifying this in VS Code insiders but could not. Is there some special setting I have to set? You say it is enabled by default on Insiders, here's what is not working for me:

  1. New python extension version, I click update
  2. Button shows up to "Restart Extensoins"
  3. I focus out of VS Code, I come back to VS Code 5 mins later. "Restart extensions" is still there 🐛

@Yoyokrazy Yoyokrazy added the verification-needed Verification of issue is requested label Jun 25, 2024
@sandy081
Copy link
Member

@isidorn It is not enabled by default. One has to opt in by enabling extensions.autoRestart setting.

@isidorn
Copy link
Contributor Author

isidorn commented Jun 25, 2024

Opted in, and now it works great. Thanks for claryfing.
Adding verified label

@isidorn isidorn added the verified Verification succeeded label Jun 25, 2024
bricefriha pushed a commit to bricefriha/vscode that referenced this issue Jun 26, 2024
@kodmanyagha
Copy link

@sandy081 I updated to version 1.91, but I didn't see that item in settings: extensions.autoRestart

@sandy081
Copy link
Member

sandy081 commented Jul 9, 2024

This feature is made available only in VS Code Insider because this can lead to strange issues and we would like to capture all of them before making this available in Stable version.

@kodmanyagha
Copy link

I'm using vscode insiders about 2 weeks and this feature is awesome and I didn't receive any problem. Please add this feature to vscode. Thanks.

@vs-code-engineering vs-code-engineering bot locked and limited conversation to collaborators Jul 28, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
author-verification-requested Issues potentially verifiable by issue author extensions Issues concerning extensions feature-request Request for new features or functionality insiders-released Patch has been released in VS Code Insiders verification-needed Verification of issue is requested verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

6 participants