ChatPage crash because of unexpected method call items
Hi team,
I found a ChatPage crash when I use refact
Code Revision: latest develop branch Reproduce Step:
- use command "Help me pull a branch from develop and create a file ddd.txt then push MR"
- Agent will generate a toolcall list like this
- Then the page crash immediately and have to restart. (will also crash when click Resume unfinished method call).
According to console log, I found the root cause - Patch Confirmation Component use those logic to fetch "to be patched file", but it assume the patch action is always the first one (toolCalls[0].function.arguments)
But the previous check tells "a patch action could be in any position of this list"
const isPatchConfirmation = commands.some((command) =>
PATCH_LIKE_FUNCTIONS.includes(command),
);
So the issues affects almost all multi-toolcall and make chat page crash (turn to blank). Please help fix it asap;
Hi @SinoReimu. Thank you for reporting this issue. A fix has been identified and added to our development backlog.
Workaround Until the fix is deployed, you can avoid the crash by breaking complex tasks into separate requests:
- First request: Make file modifications
- Second request: Perform other operations
The issue has been resolved. I am now closing this issue. If the problem persists or you have any other questions, please feel free to reopen it.