fix(voice): mark a stopped reply's running action as cancelled

The action under way when a reply stops is answered as cancelled, since it
may have taken effect, and only later calls as skipped; a stop during a
round's first action keeps that round too. The closing note no longer
claims the actions succeeded. Tests cover the refusal body read cap and
the release of an unread refusal body.
This commit is contained in:
manjunath22466 committed 2026-11-03 22:57:22 +05:30
1 parent 0a8d824124
commit c09de47d19
4 files changed
+109 -14

No files matched your search

+8 -1
View File
@@ -219,7 +219,14 @@ test('Gemini composite: chat Stop keeps the conversation and voice start ends ch
requests[2].contents
.filter((item) => item.parts[0].text)
.map((item) => item.parts[0].text),
['First', 'Done', 'Third'],
// The stopped turn stays, closed by its note.
[
'First',
'Done',
'Second',
'This reply stopped before it finished; the results above are final.',
'Third',
],
);
// Starting voice retires the typed turn in progress.
adapter.controller.start = async () => {};