Files
deepseek-harness/docs/upgrade-guide/v0.2.2-rc.1/plugin-update-method/guide.md
T
turtle1999 d2bed0238e feat(plugins): update Git-installed plugins from Discover
Discover offers Update for a plugin installed from a pinned Git commit
when the plugin index lists a newer commit of the same repository
directory. The Plugins page update removes the installed copy, installs
the target with an expected-package check that undoes a wrong install
with its modules, and reinstalls the removed commit when the target
fails. A network failure reaching the target's host stops the update
before anything is removed.
2026-11-05 01:38:32 +08:00

1.7 KiB

kind, description
kind description
upgrade-guide BundleInfo.updatable is replaced by BundleInfo.update, and ManagementError gains the unexpected-package code.

BundleInfo.update replaces BundleInfo.updatable

English | 中文

Change

pluginManager.listBundles() no longer returns BundleInfo.updatable: boolean. It returns the optional BundleInfo.update, which is 'registry' for a bundle whose newer versions listVersions reads, 'git' for a bundle installed from a Git spec pinned to a full commit, and absent for a bundle updateBundle cannot replace. A bundle that updatable: true marked before is now update: 'registry'. updateBundle also accepts a 'git' bundle when options.spec names a newer commit of the same repository directory.

ManagementError['code'] gains unexpected-package: an installation run with InstallBundleOptions.expected, which updateBundle always passes, fails with it when the spec installs another package or version.

This affects code that reads listBundles() through the Host API, @deepseek-ai/dsh-plugin-manager/types, or the remote client in @deepseek-ai/dsh-api-remotes/client, and code that switches exhaustively over ManagementError['code']. The plugin_manager tool never returned the field and is unchanged.

Migration

  1. Replace each read of updatable. To decide whether listVersions can list a bundle's versions, test bundle.update === 'registry'; to decide whether updateBundle can replace it at all, test bundle.update !== undefined.
  2. If code switches exhaustively over ManagementError['code'], handle unexpected-package.
  3. Run your type check; it succeeds when no updatable read and no unhandled ManagementError code remains.