Skip to content

Commit 5ea622d

Browse files
committed
chore: changeset for action error message fix
1 parent 6c5a7ec commit 5ea622d

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
'@objectstack/runtime': patch
3+
---
4+
5+
fix(runtime): surface the clean business message from a failed action, not the sandbox debug wrapper
6+
7+
A user throw inside a script/action body is wrapped by the sandbox as
8+
`<kind> '<name>' threw: <msg>` for server logs, but the action HTTP endpoint
9+
returned that whole wrapper as the client-facing `error` — so an action's error
10+
toast leaked the debug prefix to end users (e.g. `action 'lead_apply_convert'
11+
threw: Error: 线索信息不完整…` instead of just `线索信息不完整…`).
12+
13+
`SandboxError` now also carries `innerMessage`: the plain business message with
14+
no `<kind> '<name>' threw:` wrapper and no default `Error: ` name prefix. The
15+
action route surfaces `innerMessage` to the client and keeps the full wrapper in
16+
the server log.

0 commit comments

Comments
 (0)