fix(tui): retain stream conversation for tool denial

Capture each stream's conversation ID before starting its worker so /new cannot redirect a later action denial. Add a headless regression that mutates the active conversation while a tool request is in flight.
This commit is contained in:
Athena Kaminsky
2026-08-26 08:17:31 -05:00
committed by Athena
parent 6f5094b5fc
commit da3509eb04
2 changed files with 66 additions and 2 deletions
+3 -2
View File
@@ -354,9 +354,10 @@ class NexusTUI:
self._stop_stream.clear()
if not self.conversation_id:
self.conversation_id = str(uuid.uuid4())
conversation_id = self.conversation_id
body: dict[str, Any] = {
"message": message,
"conversation_id": self.conversation_id,
"conversation_id": conversation_id,
"history": list(self.history),
}
if self._model:
@@ -401,7 +402,7 @@ class NexusTUI:
try:
names = _deny_tool_request(
api_url=self.api_url,
conversation_id=self.conversation_id,
conversation_id=conversation_id,
payload=payload,
)
shown = ", ".join(names)