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

Better handling of dependent extension's "enablement" #23

Open
marcdumais-work opened this issue Feb 7, 2024 · 0 comments
Open

Better handling of dependent extension's "enablement" #23

marcdumais-work opened this issue Feb 7, 2024 · 0 comments

Comments

@marcdumais-work
Copy link
Contributor

marcdumais-work commented Feb 7, 2024

This extension (vscode-trace-server) is a companion to extension eclipse-cdt.vscode-trace-extension (Trace Viewer for VSCode) and depends on it.

At activation, this extension obtains a reference to the trace viewer's exported API object, and uses it to provide helper functionality. This work well normally, but there may be a corner-case that we should handle better: if/when the Trace Viewer extension becomes disabled, we probably should not use its API object any more, and if/when it becomes enabled again, we should obtain a fresh API object and redo the activation steps.

One scenario where the above might happen (to be confirmed) is when the Trace Viewer extension is updated to a new version.

As a starting point, here is how it seems the built-in vscode.github extension monitors the "enablement" of vscode.git-base it depends-on, and "refreshes" its API object when needed:

image

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

No branches or pull requests

1 participant