Skip to content

Reconnect orphaned webviews after extension host restart/crash #226069

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

segevfiner
Copy link
Contributor

Basically when the extension re-registers the webview provider and we detect an open webview editor that isn't registered in MainThreadWebviewPanels and is not dirty, we "reconnect" to it, by reinitialized it. Handling a dirty one is left for later consideration, as in that case, reinitializing it will likely lead to data loss AFAIK? Though maybe not, depending on if the state is saved on VS Code's renderer side in the model or elsewhere and if this is enough to restore it correctly.

Part of #225410 #84142 and likely other duplicates or other PR proposing a solution, continues from #225985, so you will also see the commits from it until it is merged or I rebase this branch.

@segevfiner
Copy link
Contributor Author

cc @bpasero

@ShaulAmranS
Copy link

ShaulAmranS commented Sep 15, 2024

Hi @sandy081, will this get priortized?

@segevfiner segevfiner force-pushed the reconnect-orphaned-webviews branch from 678e846 to d1f13d7 Compare September 22, 2024 09:14
Copy link
Contributor Author

@segevfiner segevfiner left a comment

Choose a reason for hiding this comment

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

Rebased. Since #225985 was merged.

@sandy081
Copy link
Member

I would leave this to @mjbvz for triaging/prioritisation as it is related completely on webviews. Let me know if you need any info from here.

@ShaulAmranS
Copy link

@mjbvz , can you take a look?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants