Files
openclaw/src/agents/tool-error-summary.ts
clawsweeper[bot] 6048cd43a5 fix(cron): keep recovered tool warnings diagnostic (#84308)
Summary:
- The PR threads middleware tool-error metadata into reply payloads, teaches cron outcome and diagnostics code to keep marked recovered warnings non-fatal, and adds focused regression coverage plus a changelog entry.
- Reproducibility: yes. Source inspection shows current main lacks a non-terminal recovered-warning path in cr ... fication, and the linked source PR includes a terminal runtime probe for the affected cron payload outcome.

Automerge notes:
- PR branch already contained follow-up commit before automerge: fix(cron): keep recovered tool warnings diagnostic

Validation:
- ClawSweeper review passed for head 8b8a36e912.
- Required merge gates passed before the squash merge.

Prepared head SHA: 8b8a36e912
Review: https://github.com/openclaw/openclaw/pull/84308#issuecomment-4491925358

Co-authored-by: abnershang <abner.shang@gmail.com>
Co-authored-by: clawsweeper <274271284+clawsweeper[bot]@users.noreply.github.com>
Co-authored-by: clawsweeper[bot] <274271284+clawsweeper[bot]@users.noreply.github.com>
Approved-by: takhoffman
Co-authored-by: takhoffman <781889+takhoffman@users.noreply.github.com>
2026-05-20 01:19:52 +00:00

21 lines
592 B
TypeScript

import { normalizeOptionalLowercaseString } from "../shared/string-coerce.js";
import type { FileTarget } from "./tool-mutation.js";
export type ToolErrorSummary = {
toolName: string;
meta?: string;
errorCode?: string;
error?: string;
timedOut?: boolean;
middlewareError?: boolean;
mutatingAction?: boolean;
actionFingerprint?: string;
fileTarget?: FileTarget;
};
const EXEC_LIKE_TOOL_NAMES = new Set(["exec", "bash"]);
export function isExecLikeToolName(toolName: string): boolean {
return EXEC_LIKE_TOOL_NAMES.has(normalizeOptionalLowercaseString(toolName) ?? "");
}