Repository navigation
chat: keep single-plugin sources installed after a reload - #333641
Merged
Merged
Conversation
A plugin installed with "Install from Source" from a repository that has only a plugin manifest, and no marketplace index, disappeared from the customizations view after a window reload. The plugin stayed on disk and stayed recorded in installed.json, but the full descriptor was never recovered, thus the installed-plugins observable discarded the entry. - Moves the single-plugin manifest fallback into the hydration step, where the recorded install directory of the entry is known. The fallback applied only to non-shorthand references before, thus it could not run for the GitHub shorthand references that "Install from Source" makes. - Reads the manifest from the recorded install directory instead of a repository path derived again from the marketplace reference. This also corrects a path mismatch for `owner/repo#ref` sources, whose clone is in `github.com/owner/repo` while the derived path added a `ref_<ref>` segment. - Makes _readPluginsForInstalledEntry do only the marketplace lookup. - Adds a regression test for a single-plugin GitHub repository that survives a restart. Fixes #333543 (Commit message generated by Copilot) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
joshspicer
previously approved these changes
Aug 31, 2026
Contributor
There was a problem hiding this comment.
Copilot review overview
Review tier: Balanced
Findings: 1
New issues introduced by this change (2)
| Severity | Finding |
|---|---|
src/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.ts — This fallback also runs when marketplace lookup succeeded but the stored plugin no longer matches… |
|
src/vs/workbench/contrib/chat/test/common/plugins/pluginMarketplaceService.test.ts — The PR specifically calls out the owner/repo#ref path mismatch, but this test uses an unqualified… |
What changed in this PR
Restores single-plugin source installations after reload by hydrating metadata from the recorded install directory.
Changes:
- Adds manifest fallback during installed-plugin hydration.
- Adds restart regression coverage.
| File | Description |
|---|---|
pluginMarketplaceService.ts |
Recovers metadata from installed manifests. |
pluginMarketplaceService.test.ts |
Tests restart hydration. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Found in review. - Applies the manifest fallback only when the marketplace supplies no plugins. A marketplace that resolves but no longer lists an entry, such as after a rename, must not fall back, because a marketplace plugin directory usually holds a manifest too and reading it rebuilt the entry as a direct source rooted at the marketplace repository, which sent later updates to the wrong repository and path. - Makes the restart test use a `#ref` reference, so the recorded clone directory and the directory derived from the reference differ. The test now proves that hydration reads the recorded install directory. - Adds a test that a marketplace plugin the marketplace no longer lists stays unhydrated. (Commit message generated by Copilot) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Dmitriy Vasyura (dmitrivMS)
approved these changes
Aug 31, 2026
This was referenced Oct 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


chat: keep single-plugin sources installed after a reload
A plugin installed with "Install from Source" from a repository that has only a plugin manifest,
and no marketplace index, disappeared from the customizations view after a window reload. The
plugin stayed on disk and stayed recorded in installed.json, but the full descriptor was never
recovered, thus the installed-plugins observable discarded the entry.
directory of the entry is known. The fallback applied only to non-shorthand references before,
thus it could not run for the GitHub shorthand references that "Install from Source" makes.
again from the marketplace reference. This also corrects a path mismatch for
owner/repo#refsources, whose clone is in
github.com/owner/repowhile the derived path added aref_<ref>segment.
Fixes #333543
(Commit message generated by Copilot)
Co-authored-by: Copilot 223556219+Copilot@users.noreply.github.com