Self Checks
To make sure we get to you in time, please check the following :)
Versions
- dify-plugin-daemon Version:
main
- dify-api Version:
1.14.0
Describe the bug
There is an inconsistency in plugin_id generation/usage for remote debugging plugins:
- In listing/query logic,
plugin_id is derived from plugin_unique_identifier.PluginID().
- For remote runtime,
RemotePluginRuntime.Identity() rewrites author to tenant_id, so plugin_unique_identifier becomes ${tenant_id}/${plugin_name}:..., and plugin_id becomes ${tenant_id}/${plugin_name}.
- During remote installation,
curd.InstallPlugin forcibly overrides remote plugin_id to ${declaration.author}/${declaration.name}.
This creates a mismatch between:
- what list/query APIs return (
${tenant_id}/${plugin_name}),
- and what installation-related tables store (
${author_name}/${plugin_name}).
As a result, when clicking a plugin in the plugin page (which uses returned plugin_id for follow-up queries), backend lookup can fail and UI shows server internal error.
To Reproduce
Steps to reproduce the behavior:
- Enable remote plugin installing/debugging mode.
- Connect a remote debugging plugin with
declaration.author != tenant_id.
- Open plugin list page and observe returned
plugin_id (tenant-based form like ${tenant_id}/${plugin_name}).
- Click this plugin to open detail/config page.
- See error (
server internal error) due to plugin_id mismatch in subsequent queries.
Expected behavior
plugin_id should be consistent across:
- listing APIs,
- installation records,
- and detail/follow-up query APIs.
Remote plugins should use one canonical plugin_id format end-to-end (either tenant-based or declaration-author-based), without rewriting to a different format in another layer.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Potentially relevant code paths:
internal/core/debugging_runtime/type.go
RemotePluginRuntime.Identity() rewrites config.Author = tenantId, producing tenant-based identifier/plugin_id.
internal/service/manage_plugin.go
ListPlugins() returns PluginID: pluginUniqueIdentifier.PluginID().
internal/types/models/curd/atomic.go
InstallPlugin() for remote explicitly overrides pluginID = declaration.Author + "/" + declaration.Name.
internal/service/install_service/controlpanel.go
remote connect path triggers install via InstallListener.OnDebuggingRuntimeConnected().
The mismatch appears after introducing remote plugin_id override in install flow.
Self Checks
To make sure we get to you in time, please check the following :)
Versions
main1.14.0Describe the bug
There is an inconsistency in
plugin_idgeneration/usage for remote debugging plugins:plugin_idis derived fromplugin_unique_identifier.PluginID().RemotePluginRuntime.Identity()rewritesauthortotenant_id, soplugin_unique_identifierbecomes${tenant_id}/${plugin_name}:..., andplugin_idbecomes${tenant_id}/${plugin_name}.curd.InstallPluginforcibly overrides remoteplugin_idto${declaration.author}/${declaration.name}.This creates a mismatch between:
${tenant_id}/${plugin_name}),${author_name}/${plugin_name}).As a result, when clicking a plugin in the plugin page (which uses returned
plugin_idfor follow-up queries), backend lookup can fail and UI showsserver internal error.To Reproduce
Steps to reproduce the behavior:
declaration.author != tenant_id.plugin_id(tenant-based form like${tenant_id}/${plugin_name}).server internal error) due toplugin_idmismatch in subsequent queries.Expected behavior
plugin_idshould be consistent across:Remote plugins should use one canonical
plugin_idformat end-to-end (either tenant-based or declaration-author-based), without rewriting to a different format in another layer.Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Potentially relevant code paths:
internal/core/debugging_runtime/type.goRemotePluginRuntime.Identity()rewritesconfig.Author = tenantId, producing tenant-based identifier/plugin_id.internal/service/manage_plugin.goListPlugins()returnsPluginID: pluginUniqueIdentifier.PluginID().internal/types/models/curd/atomic.goInstallPlugin()for remote explicitly overridespluginID = declaration.Author + "/" + declaration.Name.internal/service/install_service/controlpanel.goremote connect path triggers install via
InstallListener.OnDebuggingRuntimeConnected().The mismatch appears after introducing remote
plugin_idoverride in install flow.