Improve the output of patch get command to show pipeline information
What
This change enhances the output of the patch get command by adding detailed pipeline and deployment status tracking. When users view a patch, they now see additional information, including:
- Links to the latest patch file commit for all patch statuses
- Deployment pipeline link for in-rollout patches
- Timestamp shown for the latest commits
- Current pipeline status for in-rollout patches.
- Failed patches already have a link to the failed pipeline; the pending packages only have skipped pipelines
- Link for the commit history related to the patch
The enhancement helps quickly understand what's the current status of the patches by providing direct links to the related commits and pipelines.
Related issue: https://gitlab.com/gitlab-com/gl-infra/delivery/-/issues/21599
Testing
- When the patch is rolling out
- When the patch is pending state
- When the patch failed
-
There's no failed patch at the moment so I manually added an
errorkeyword to one of the existing patches locally -
Diff
diff --git a/patches/cellsdev/01K9B60P6E7X4QZ4D29DGP8ZB7.json b/patches/cellsdev/01K9B60P6E7X4QZ4D29DGP8ZB7.json index 465685098..5a1f02d2b 100644 --- a/patches/cellsdev/01K9B60P6E7X4QZ4D29DGP8ZB7.json +++ b/patches/cellsdev/01K9B60P6E7X4QZ4D29DGP8ZB7.json @@ -9,6 +9,7 @@ "only_gitlab_upgrade": true, "in_rollout": false, "origin": "auto_deploy", + "error": "Pipeline failure https://ops.gitlab.net/gitlab-com/gl-infra/cells/tissue/-/pipelines/5163114", "last_status_update": "2025-11-06T00:14:10.728263881Z", "patch": [ {
-
- Using non-existing patch ID:
-
Output
go run main.go -C ../Cells-canonical/tissue patch get 01K9BBBRYEP07YP0A4T0ZHKM1V time=2025-11-06T21:53:08.157+08:00 level=WARN msg="DELIVERY_METRICS_URL or DELIVERY_METRICS_TOKEN not set, disabling metrics" DELIVERY_METRICS_URL="" time=2025-11-06T21:53:08.160+08:00 level=INFO msg="tissue client initialized" instance=https://ops.gitlab.net branch=main dry_run=false amp=cellsdev project=gitlab-com/gl-infra/cells/tissue version=dev-gunknow-dirty local=false time=2025-11-06T21:53:11.314+08:00 level=ERROR msg="patch not found" patch_id=01K9BBBRYEP07YP0A4T0ZHKM1V tip="Use 'ringctl patch ls' to see all active patches"
-
Why
Links to relevant issues
Edited by Mawreen Dela Cruz


