Loading
Add link between workflows and notes they create
What does this MR do and why?
Previous MRs:
- Linking to merge requests
- Linking to work items
Add link between workflows and notes they create
When a workflow creates a note, for example through glab, then this change creates a link between the workflow and the notes
References
Relates to #600655 (closed)
Screenshots or screen recordings
| Before | After |
|---|---|
How to set up and validate locally
- Ensure this FF is disabled:
duo_workflow_use_hardened_image - Ask duo developer a question, e.g.
@duo-developer-gitlab-duo - What time is it? - Confirm the flow responded to you with a new comment
- In your rails console, validate the link to the created comment was created, with
link_type: "created"
[1] pry(main)> workflow = Ai::DuoWorkflows::Workflow.last
[2] pry(main)> workflow.linked_notes
=> [#<DiscussionNote:0x000000013c2a6510
note: [FILTERED],
noteable_type: "MergeRequest",
...
[3] pry(main)> workflow.note_links
=> [#<Ai::DuoWorkflows::WorkflowNote:0x0000000140ee9710
id: 1,
workflow_id: 4564,
note_id: 10767,
project_id: 22,
namespace_id: nil,
created_at: "2026-07-02 22:03:36.530947000 +0000",
updated_at: "2026-07-02 22:03:36.530947000 +0000",
link_type: "created">]
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.
Edited by Roman Eisner