UNPKG

openclaw

Version:

Multi-channel AI gateway with extensible messaging integrations

3 lines • 1.15 kB
import{a as toAcpRuntimeError}from"./errors-C1zF32os.mjs"; //!packages/acp-core/src/runtime/error-text.ts const ACP_RUNTIME_ERROR_NEXT_STEPS={ACP_BACKEND_MISSING:"Run `/acp doctor`, install/enable the backend plugin, then retry.",ACP_BACKEND_UNAVAILABLE:"Run `/acp doctor`, install/enable the backend plugin, then retry.",ACP_DISPATCH_DISABLED:"Enable `acp.dispatch.enabled=true` to allow thread-message ACP turns.",ACP_SESSION_INIT_FAILED:"If this session is stale, recreate it with `/acp spawn` and rebind the thread.",ACP_INVALID_RUNTIME_OPTION:"Use `/acp status` to inspect options and pass valid values.",ACP_BACKEND_UNSUPPORTED_CONTROL:`This backend does not support that control; use a supported command.`,ACP_TURN_FAILED:"Retry, or use `/acp cancel` and send the message again."};function formatAcpRuntimeErrorText(e){const t=Object.hasOwn(ACP_RUNTIME_ERROR_NEXT_STEPS,e.code)?ACP_RUNTIME_ERROR_NEXT_STEPS[e.code]:void 0;return`ACP error (${e.code}): ${e.message}${t?`\nnext: ${t}`:``}`}function toAcpRuntimeErrorText(e){return formatAcpRuntimeErrorText(toAcpRuntimeError(e))}export{toAcpRuntimeErrorText as n,formatAcpRuntimeErrorText as t};