Add Retry to failed and cancelled sessions in the Sessions widget

What does this MR do and why?

Add Retry to failed and cancelled sessions in the Sessions widget

  • Show a Retry button on failed and cancelled session rows in the Sessions widget on work items and merge requests
  • Refresh the sessions list after a retry, so the new session shows under Created
  • Request restartDuoWorkflow in the work item and merge request session queries to drive the button's visibility
  • Rename the session actions' isSidePanel prop to displayMinimal, so the widget row can reuse its icon buttons, and add iconButtonCategory so the widget's Retry is borderless

Plan

# MR What it adds
1 Add Retry to failed and cancelled sessions in the Sessions widget Retry button on failed and cancelled sessions, at the end of the row and borderless
2 Expose restartedAs on the DuoWorkflow GraphQL type restartedAs field, so the widget can tell a session was retried
3 Show a View retry link on retried sessions in the Sessions widget Retried failed and cancelled sessions get a View retry link

We split it this way so the Retry button (1) can merge without waiting on the backend field (2). Only the design feedback on what happens after a retry needs the new field, so that part (3) is stacked on 2.

See design and UX discussion - !263742 (comment 4059242321)

References

Screenshots or screen recordings

Screenshot of sessions widget Video of retry behaviour When the retry fails (toast message)
Screenshot_2026-11-09_at_1.46.56_PM

How to set up and validate locally

  1. Prerequisite: Have GitLab Duo set up in your GDK or Caproni
    • Have a Duo-enabled group and project created by the Duo setup above
  2. Prerequisite: Have GitLab Runner working in your GDK or Caproni
  3. Enable the dap_session_restarts feature flag.
  4. Start a session from an issue in the Duo-enabled project. For example, select Implement on the issue.
  5. Open the session at /<project full path>/-/automate/agent-sessions/<session ID>.
  6. Select Cancel session.
  7. Go back to the issue and expand the Sessions widget. The cancelled session shows a borderless Retry icon button at the end of its row.
  8. Select Retry. The new session appears under Created.
  9. Disable the dap_session_restarts feature flag and reload the issue. The cancelled session has no Retry button.

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 Allison Villa

Merge request reports

Loading
Loading