`Troubleshoot` and similar buttons should create a new thread on Duo Chat
Context
When Duo Chat multithreaded mode is enabled, any button that opens Duo Chat and performs an action is not working properly. For example, if you click the button and Duo Chat is already open, it adds it to the previous thread. Or if Duo Chat is closed or on the list view, it does not work. The correct behavior is that it should create a new thread and switch to the new thread.
Affected Functionality
- Troubleshoot button
- Explain Vulnerability button
- View summary button
- Explain code button (question mark icon when code is selected)
Acceptance criteria
When I click Troubleshoot, Explain Vulnerability, View summary, or the Explain code question mark icon in single-threaded mode:
- It should respond in the current thread
When I click Troubleshoot, Explain Vulnerability, View summary, or the Explain code question mark icon from the chat history page in multithreaded mode:
- It should create a new thread
- And respond in the new thread
When I click Troubleshoot, Explain Vulnerability, View summary, or the Explain code question mark icon from any other screen in multithreaded mode:
- It should create a new thread
- And respond in the new thread
When I type or select /troubleshoot, /vulnerability_explain, /summarize_comments, or /explain in the chat box
- Respond in the current thread