diff --git a/src/config/plugin-auto-enable.ts b/src/config/plugin-auto-enable.ts index 6cf09647cf6..61c375e6d2e 100644 --- a/src/config/plugin-auto-enable.ts +++ b/src/config/plugin-auto-enable.ts @@ -437,7 +437,6 @@ function registerPluginEntry(cfg: OpenClawConfig, pluginId: string): OpenClawCon ...cfg.channels, [builtInChannelId]: { ...existingRecord, - enabled: true, }, }, }; @@ -516,7 +515,7 @@ export function applyPluginAutoEnable(params: { ) { return false; } - return (channelConfig as { enabled?: unknown }).enabled === true; + return (channelConfig as { enabled?: unknown }).enabled !== false; })() : next.plugins?.entries?.[entry.pluginId]?.enabled === true; if (alreadyEnabled && !allowMissing) { diff --git a/src/gateway/server-methods/agent.ts b/src/gateway/server-methods/agent.ts index bd5637fa78f..fd9404955aa 100644 --- a/src/gateway/server-methods/agent.ts +++ b/src/gateway/server-methods/agent.ts @@ -731,6 +731,7 @@ export const agentHandlers: GatewayRequestHandlers = { const agentIdRaw = typeof p.agentId === "string" ? p.agentId.trim() : ""; const sessionKeyRaw = typeof p.sessionKey === "string" ? p.sessionKey.trim() : ""; let agentId = agentIdRaw ? normalizeAgentId(agentIdRaw) : undefined; + const cfg = loadConfig(); if (sessionKeyRaw) { if (classifySessionKeyShape(sessionKeyRaw) === "malformed_agent") { respond( @@ -743,7 +744,7 @@ export const agentHandlers: GatewayRequestHandlers = { ); return; } - const resolved = resolveAgentIdFromSessionKey(sessionKeyRaw); + const resolved = resolveSessionAgentId({ sessionKey: sessionKeyRaw, config: cfg }); if (agentId && resolved !== agentId) { respond( false, @@ -757,7 +758,6 @@ export const agentHandlers: GatewayRequestHandlers = { } agentId = resolved; } - const cfg = loadConfig(); const identity = resolveAssistantIdentity({ cfg, agentId }); const avatarValue = resolveAssistantAvatarUrl({ diff --git a/src/version.ts b/src/version.ts index 806928103cd..f95610d13b6 100644 --- a/src/version.ts +++ b/src/version.ts @@ -114,6 +114,7 @@ export function resolveRuntimeServiceVersion( runtimeVersion, env["OPENCLAW_SERVICE_VERSION"], env["npm_package_version"], + VERSION, ) ?? fallback ); }