fix(gateway): preserve traced child sessions

This commit is contained in:
Nimrod Gutman
2026-05-28 17:26:51 +03:00
parent f6e51ff99a
commit 3f3ed5ec66
3 changed files with 8 additions and 1 deletions

View File

@@ -17,6 +17,7 @@ Docs: https://docs.openclaw.ai
- Status: show active subagent details in status output.
- Diffs: split the default language pack and expand default Diffs language coverage while keeping the host floor aligned. (#87370, #87372) Thanks @RomneyDa.
- ClawHub: add plugin display names plus skill verification and trust surfaces. (#87354, #86699) Thanks @thewilloftheshadow and @Patrick-Erichsen.
- iOS: refresh the dev app with Pro Command, Chat, Agents, and Settings tabs wired to gateway sessions, diagnostics, chat, and realtime Talk. (#87367) Thanks @Solvely-Colin.
- Docs: clarify Codex computer-use setup, paste-token stdin auth setup, macOS gateway sleep troubleshooting, native Codex hook relay recovery, container model auth, install deployment cards, device-token admin gating, and backport targets. (#87313, #63050) Thanks @bdjben, @liaoandi, and @thewilloftheshadow.
### Fixes

View File

@@ -152,7 +152,9 @@ function filterSessionStoreToConfiguredAgents(
);
}
function inheritSessionRuntimeSelection(parentEntry: SessionEntry | undefined): Partial<SessionEntry> {
function inheritSessionRuntimeSelection(
parentEntry: SessionEntry | undefined,
): Partial<SessionEntry> {
if (!parentEntry) {
return {};
}
@@ -173,6 +175,7 @@ function inheritSessionRuntimeSelection(parentEntry: SessionEntry | undefined):
...(parentEntry.thinkingLevel ? { thinkingLevel: parentEntry.thinkingLevel } : {}),
...(typeof parentEntry.fastMode === "boolean" ? { fastMode: parentEntry.fastMode } : {}),
...(parentEntry.verboseLevel ? { verboseLevel: parentEntry.verboseLevel } : {}),
...(parentEntry.traceLevel ? { traceLevel: parentEntry.traceLevel } : {}),
...(parentEntry.reasoningLevel ? { reasoningLevel: parentEntry.reasoningLevel } : {}),
...(parentEntry.elevatedLevel ? { elevatedLevel: parentEntry.elevatedLevel } : {}),
...(parentEntry.authProfileOverride

View File

@@ -97,6 +97,7 @@ test("sessions.create inherits parent runtime model selection when model is omit
model: "gpt-5.5",
contextTokens: 272000,
thinkingLevel: "off",
traceLevel: "debug",
authProfileOverride: "codex-oauth",
authProfileOverrideSource: "user",
}),
@@ -114,6 +115,7 @@ test("sessions.create inherits parent runtime model selection when model is omit
model?: string;
contextTokens?: number;
thinkingLevel?: string;
traceLevel?: string;
authProfileOverride?: string;
authProfileOverrideSource?: string;
parentSessionKey?: string;
@@ -134,6 +136,7 @@ test("sessions.create inherits parent runtime model selection when model is omit
expect(created.payload?.entry?.model).toBe("gpt-5.5");
expect(created.payload?.entry?.contextTokens).toBe(272000);
expect(created.payload?.entry?.thinkingLevel).toBe("off");
expect(created.payload?.entry?.traceLevel).toBe("debug");
expect(created.payload?.entry?.authProfileOverride).toBe("codex-oauth");
expect(created.payload?.entry?.authProfileOverrideSource).toBe("user");