fix: finish exec tool failure landing (#52508) (thanks @martingarramon)

This commit is contained in:
Peter Steinberger 2026-03-23 02:18:15 +00:00
parent 22c75a55b0
commit f8731b3d9d
2 changed files with 14 additions and 3 deletions

View File

@ -106,6 +106,7 @@ Docs: https://docs.openclaw.ai
- Mattermost/threading: honor `replyToMode: "off"` for already-threaded inbound posts so threaded follow-ups can fall back to top-level replies when configured. (#52543) Thanks @RichardCao.
- Telegram/replies: set `allow_sending_without_reply` on reply-targeted sends and media-error notices so deleted parent messages no longer drop otherwise valid replies. (#52524) Thanks @moltbot886.
- Gateway/status: resolve env-backed `gateway.auth.*` SecretRefs before read-only probe auth checks so status no longer reports false probe failures when auth is configured through SecretRef. (#52513) Thanks @CodeForgeNet.
- Agents/exec: return plain-text failed tool output for timeouts and other non-success exec outcomes so models no longer parrot raw JSON error payloads back to users. (#52508) Thanks @martingarramon.
- CLI/startup: lazy-load channel add and root help startup paths to trim avoidable RSS and help latency on constrained hosts. (#46784) Thanks @vincentkoc.
- CLI/onboarding: import static provider definitions directly for onboarding model/config helpers so those paths no longer pull provider discovery just for built-in defaults. (#47467) Thanks @vincentkoc.
- CLI/configure: clarify fresh-setup memory-search warnings so they say semantic recall needs at least one embedding provider, and scope the initial model allowlist picker to the provider selected in configure. Thanks @vincentkoc.

View File

@ -462,11 +462,21 @@ describe("exec tool backgrounding", () => {
allowBackground: false,
});
const result = await executeExecCommand(customBash, longDelayCmd);
const text = (result as { content: { text: string }[] }).content[0].text;
const text = readTextContent(result.content);
expect(text).toMatch(/timed out/i);
expect(text).toMatch(/re-run with a higher timeout/i);
const details = (result as { details: { status: string } }).details;
expect(details.status).toBe("failed");
const details = result.details as {
status?: string;
exitCode?: number | null;
durationMs?: number;
aggregated?: string;
};
expect(details).toMatchObject({
status: "failed",
exitCode: null,
aggregated: "",
});
expect(details.durationMs).toEqual(expect.any(Number));
});
it.each<DisallowedElevationCase>(DISALLOWED_ELEVATION_CASES)(