zjncs opened a new pull request, #5741:
URL: https://github.com/apache/rocketmq-dashboard/pull/5741

   ### What
   
   `ToolExecutionException` — the typed failure a tool call surfaces — had no 
test. This adds `ToolExecutionExceptionTest` with 4 tests.
   
   ### What is pinned
   
   - the exception carries the HTTP status, the message, the machine error code 
and the recovery hint;
   - **a `ToolExecutionException` passes through `from()` untranslated** — its 
identity, code and hint survive;
   - a foreign `BusinessException` is translated to the structured 
`TOOL_EXECUTION_FAILED` with its message preserved, the standard hint, **and 
the original chained as the cause**;
   - an unresolvable HTTP status falls back to 500 rather than crashing the 
translation.
   
   ### Verification
   
   - New tests on unmodified code: **4/4 green**, checkstyle clean (`mvn test 
-Dtest=ToolExecutionExceptionTest`).
   - Discriminating mutations on `ToolExecutionException`, build result 
verified red each time:
     1. the pass-through dropped so tool failures get retranslated and lose 
their identity — red;
     2. the unresolvable-status fallback changed to 400 — red;
     3. the cause chain dropped from the translation — red.
   - Restored: 4/4 green. Test-only change; no product code touched.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to