Fix Duo Chat buttons that do not work on multithreaded mode
What does this MR do and why?
This MR fixes buttons that do not currently work on Duo Chat multithreaded mode by setting the 'fromButton' flag.
References
Screenshots or screen recordings
N/A
How to set up and validate locally
Troubleshoot button
Prerequisites:
- Vulnerability must be of
sasttype to receive the/vulnerability_explaincommand
Steps:
-
Create vulnerability via UI:
- Navigate to
Secure -> Vulnerability report -> Submit vulnerability - Required fields:
- Identifier code: e.g. "1228"
- URL: e.g. "https://cwe.mitre.org/data/definitions/1228.html"
- Navigate to
-
Update type in rails console:
# Convert to sast type
Vulnerability.last.update!(report_type: :sast)
- To skip complex setup, just hardcode this to
truefor now😅 - Click on the vulnerability from the list and test the 'Explain with AI' button
- It should create a new thread
Explain with AI
- Go to any code file
- Select code
- Click the question mark
- It should create a new thread
View summary
- Go to an issue page
- Click 'view summary'
- It should create a new thread
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Related to #526951 (closed)
Edited by Lesley Razzaghian
