fix(agent): close runtime context persistence gaps

This commit is contained in:
chengyongru authored and Xubin Ren committed 2026-07-12 00:35:17 +08:00
1 parent f75d3519db
commit 2eb7398f34
10 files changed
+235 -20

No files matched your search

+4 -2
View File
@@ -216,7 +216,8 @@ class Session:
content = f"{content}\n{breadcrumbs}" if content else breadcrumbs
cli_apps = message.get("cli_apps")
if (
not has_persisted_runtime_context
include_runtime_context
and not has_persisted_runtime_context
and role == "user"
and isinstance(cli_apps, list)
and cli_apps
@@ -239,7 +240,8 @@ class Session:
content = f"{content}\n{breadcrumbs}" if content else breadcrumbs
mcp_presets = message.get("mcp_presets")
if (
not has_persisted_runtime_context
include_runtime_context
and not has_persisted_runtime_context
and role == "user"
and isinstance(mcp_presets, list)
and mcp_presets