Loading
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
restartDuoWorkflowin the work item and merge request session queries to drive the button's visibility - Rename the session actions'
isSidePanelprop todisplayMinimal, so the widget row can reuse its icon buttons, and addiconButtonCategoryso 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
- Related to FE: Add retry button to sessions widgets compon... (#598747 - closed) • Allison Villa • 19.6 • At risk
- Backend MR for the follow-up: Expose restartedAs on the DuoWorkflow GraphQL type (!268886 - merged) • Allison Villa • 19.6
- Stacked follow-up: Show a View retry link on retried sessions in t... (!268887 - merged) • Allison Villa • 19.6
- Epic: Session Resilience & Recovery (gitlab-org#22549) • Unassigned • 19.7 • On track
- Related: Show the source session of a restarted session ... (!267648 - merged) • Allison Villa • 19.6
Screenshots or screen recordings
| Screenshot of sessions widget | Video of retry behaviour | When the retry fails (toast message) |
|---|---|---|
![]() |
How to set up and validate locally
- Prerequisite: Have GitLab Duo set up in your GDK or Caproni
- Have a Duo-enabled group and project created by the Duo setup above
- Prerequisite: Have GitLab Runner working in your GDK or Caproni
- Enable the
dap_session_restartsfeature flag. - Start a session from an issue in the Duo-enabled project. For example, select Implement on the issue.
- Open the session at
/<project full path>/-/automate/agent-sessions/<session ID>. - Select Cancel session.
- 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.
- Select Retry. The new session appears under Created.
- Disable the
dap_session_restartsfeature 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
