{"data":{"slug":"discovered-721cfe580cc8e94c7336faca41099716587e105245298901","title":"Update Step Status on GitLab Work Item","summary":"Update the Status table on a GitLab work item by setting a step's MRs or status, and recompute which steps are blocked, ready for development, or blocked but can be stacked on one existing MR.","url":"https:\/\/skillshunter.net\/skills\/discovered-721cfe580cc8e94c7336faca41099716587e105245298901","json_url":"https:\/\/skillshunter.net\/api\/public\/v1\/skills\/discovered-721cfe580cc8e94c7336faca41099716587e105245298901","markdown_url":"https:\/\/skillshunter.net\/skills\/discovered-721cfe580cc8e94c7336faca41099716587e105245298901.md","download_url":"https:\/\/skillshunter.net\/skills\/discovered-721cfe580cc8e94c7336faca41099716587e105245298901\/download","category":{"slug":"software-development","name":"Software & Development"},"editor_note":"Run `scripts\/update-step-status.py` with a GitLab work item URL (e.g., `https:\/\/gitlab.com\/<project>\/-\/work_items\/<iid>`) or a local file path. The script will query GitLab for MR status and update the work item's Status table accordingly. A `--dry-run` option is available to preview changes before writing.","instructions":"---\nname: update-step-status\ndescription: >\n  Update the Status table on a plan's GitLab work item: set a step's MRs or\n  status, then recompute which steps are blocked, ready for development, or\n  blocked but can be stacked on one existing MR. Use for \"update the status\n  table on <work item url>\", \"mark steps 5, 8 as complete\", \"set !123 as the\n  MR for step 6\", \"what's unblocked now\", \"refresh the blocked rows\".\nargument-hint: \"<work item url> [what to set]\"\n---\n\n# Step status table\n\nRun `scripts\/update-step-status.py` (stdlib Python, shells out to `glab api`). The URL\nlooks like `https:\/\/gitlab.com\/<project>\/-\/work_items\/<iid>`; ask for it when\n`$ARGUMENTS` has none. A local file path works too and never writes.\n\nThe Status table is found by its `#`, `MR`, `Status` and `Dependencies` headers\n(`Done` is optional), as an HTML `<table>` or a markdown pipe table. A write\nkeeps the table's own format: a pipe table stays a pipe table, and Done is\nticked as `[x]` there and `* [x]` in HTML. `no_table` means neither format has\nthose headers.\n\n| Need | Command |\n| --- | --- |\n| Rows with status, MRs, open blockers | `update-step-status.py show <url>` |\n| Set statuses and MRs | `update-step-status.py update <url> --status 5=complete --mr 6=!4308,!4309` |\n| Recompute derived states | `update-step-status.py update <url> --refresh` |\n| Preview any of these | add `--dry-run` |\n\n`--status` takes `complete`, `in dev`, `in review`, `blocked` or\n`ready for development`; `complete` also ticks Done. `--mr N=-` clears the cell.\n`--status` and `--mr` apply first, then `--refresh`, so one call covers a\ncompletion and its cascade.\n\nA row id is a number with an optional letter (`6`, `6a`, `6b`). Each id is its\nown row, with its own Status, MRs and Done cell, and `--status` and `--mr` take\nthe full id. A bare `6` matches only a row whose id is exactly `6`; with no such\nrow the call returns `no_step`. Any other id in the `#` column is an `error`.\n\n## What `--refresh` does\n\nFirst it queries GitLab for the MRs in each `in dev` or `in review` row and\nmarks the row `complete` (Done ticked) when every listed MR has merged. A row\nwith no MRs is left alone. Next it moves an `in dev` row to\n`~\"workflow::in review\"` when any of its MRs is open and has a human reviewer\nassigned. A bot is a user GitLab flags `bot: true` (GitLab Duo is one) or one in\nthe script's `BOTS` list, and it doesn't count. A draft MR counts like any other, and a closed or merged MR\ndoesn't. The move is one way: a reviewer removed later leaves the row in\nreview. Then it recomputes rows whose\nStatus is `blocked` or `ready for development`, so a merge cascades in one call.\nRows in dev, in review or complete are otherwise never changed.\n\n| Row's open blockers | Result |\n| --- | --- |\n| none | `~\"workflow::ready for development\"` |\n| one step, and that step has exactly one unmerged MR | `~\"workflow::blocked\" but can be stacked on !<MR>` |\n| anything else | `~\"workflow::blocked\"` |\n\nIn Dependencies a lettered id counts as its number: `Step 6`, `Step 6a` and\n`Step 6b` all name step 6, which is complete only when every row numbered 6 is.\nSo a row that depends on `6a` stays blocked while `6b` is open. A blocker whose\nincomplete rows all hold MRs that have all merged (read from GitLab) no longer\nblocks, even if its rows aren't marked complete. A blocker can be stacked on only\nwhen its incomplete rows hold exactly one unmerged MR between them, so a step with\nseveral MRs where one is still open is stacked on that one.\n\nA blocker is a step in Dependencies that isn't complete. Text after a `;`, or a\ncell with no `Step N`, is work outside the plan: it blocks (never ready, never\nstackable) unless it says `merged` or `for ordering only`.\n\n## Writing\n\nPreview with `--dry-run` and show the user the `completed`, `in_review` and `refreshed` lists, then write.\nWriting a GitLab work item needs the user's ask in the same turn. A step's\nblocker with two or more unmerged MRs can't be stacked on, so its dependents stay plain blocked.\n\nThe script re-reads the description just before the PUT, aborts with\n`changed` if it moved, and reads it back (`verify_failed` if it differs).\nOther statuses: `ok`, `dry_run`, `no_table`, `no_step`, `bad_label`, `bad_arg`,\n`bad_url`, `error`; report the `message`.\n\nOverlaps `claim-step`, which sets Assignee and `in dev`; use that to claim and\nthis for everything else in the table.\n","use_cases":["Update the status table on a specific GitLab work item URL","Mark specific steps as complete","Set a specific MR as the MR for a step","Refresh the blocked rows in the Status table","Preview changes before applying them to a work item"],"limitations":[],"compatibility":[],"setup_tip":null,"sample_input":null,"sample_output":null,"source_url":"https:\/\/gitlab.com\/radbatnag\/claude-skills\/-\/blob\/ea806e8929364f9666ab6b04d6c4e28b56f1f2ea\/skills\/update-step-status\/SKILL.md","source_commit":"ea806e8929364f9666ab6b04d6c4e28b56f1f2ea","license":null,"version":null,"listing_approved_at":"2026-12-03","created_at":"2026-12-02T06:54:59.000000Z","updated_at":"2026-12-03T16:19:55.000000Z","seo_title":"Update GitLab Work Item Step Status","seo_description":"Automatically update the Status table on a GitLab work item by setting step MRs or status, and recompute blocked or ready steps based on MR status.","seo_keywords":["GitLab work item","update step status","MR status","blocked steps","ready for development","GitLab API","Python script","status table"]}}