Post deploy verification

From makifbaysal/tasktrooper · View interactive version

Post deploy verification is an AI agent skill from the GitHub repository makifbaysal/tasktrooper. Use when a release reaches awaiting_verdict (or you are woken for an incident) - how to read runtime logs, error groups, health and smoke evidence for the release's component and decide finish, re-check, roll back or hand to a human

How to use this skill

Skill file

Post-deploy verification

A deploy that went green tells you the process started. It says nothing about whether the change it shipped actually works, or whether it broke something else that happened to keep running. Verification is what closes that gap, and it happens every time — not only when something looks wrong.

1. Procedure — exact calls

  1. get_release({ task_id }) → read deployed_at, component, checks (health samples, smoke results, new_errors, notes, early_stop), profile.auto_rollback, and tasks[] — every task this release covers, not only the one you were woken on.
  2. get_environment only if you need to confirm nothing is bound (checks.notes already says so in most cases).
  3. list_runtime_errors({ component, since: "<window that starts well before deployed_at>" }) — see "Reading error groups" below for the window and how to judge new.
  4. query_runtime_logs({ component, since: deployed_at, min_severity: "error" }); re-query with text: set to a route or module the release changed when the error list alone is not enough.
  5. run_smoke_checks({ task_id }) when the stored evidence is older than ~30 minutes, or when early_stop itself came from a smoke failure and you need a fresh read before deciding.
  6. One read-only acceptance check per observable criterion of every task in release.tasks (list_acceptance_criteria per task) — a release with several tasks is verified in full, not just the card that woke you.

2. Reading error groups

list_runtime_errors' new: true is accurate on a provider with native grouping (gcloud). On a provider without one (Vercel, AWS — fallback fingerprint grouping), it only means "this group's first occurrence fell in the back half of whatever window you queried" — querying since: deployed_at puts a regression that starts right after the deploy in the window's front half, so it can read new: false and never show up as a concern.

3. Verdict table

Evidence maps to one of four outcomes — finish, re-check once, roll back, or hand to a human — the same shape as Argo Rollouts' Successful/Failed/Inconclusive and Flagger's "N failed checks before rollback": one blip is not a trend, and an unreadable signal is not a pass.

| Evidence | Verdict |

|---|---|

| early_stop: smoke check failed | Re-run run_smoke_checks once. Passes, and no error group has first_seen >= deployed_at → finish, naming the transient failure and the re-check. Fails again → rollback_release (verify_failed). |

| Health check failed twice | fetch_url the checks.health_url once (GET). Still failing → roll back. Recovered → look for a restart/crash line in the logs since deployed_at; clean → finish, noting the blip. |

| An error group with first_seen >= deployed_at whose message, path or stack touches a file or route this release's tasks changed (get_task_pull_request({ task_id, include_diff: false }) → files) | Roll back (verify_failed). |

| Same, but unrelated and it also recurs before the deploy in a 1d read | Finish, naming each group and why it is not a regression. |

| Only structural gaps in notes (no bound environment, no health URL, no base URL) | Finish, stating the gap verbatim — it is a different kind of verification, not a failed one. |

| A runtime tool itself errored | Retry once. Still failing, and health and smoke are both green → finish, saying the logs were unreadable this run. |

| Nothing at all is readable for an on_merge/dispatch service (no health, no smoke, no logs, and the retry above also failed) | One comment: "verdict needs a human: no evidence was readable (<what you tried>)" — and stop. A human finishes or rolls back from the Deploy tab. This is the one case where "finish with the gap stated" is not the default: with nothing readable there is no evidence to finish on. |

Recording a missing deploy target

A notes gap like "no health URL" or "no base URL" does not always mean nobody can fix it — if the deploy's own output (get_deploy_logs, a local_run.tail, or a workflow log) names the real URL the service answers on, update_deploy_target({ env, base_url / health_url / logs_url }) records it so the next soak and verdict actually have something to read, instead of hitting the same gap every release. Still finish or roll back on the evidence you have in THIS run — recording the target fixes the next one, it does not retroactively create evidence for this one.

4. Feature-flagged changes

If a task's after_deploy (on release.tasks[]) enables a flag or config, its new behaviour is not reachable yet — that is expected, not a failure. Check that the old path still works, and say "criterion X is behind flag Y, enabled after release by a human" in your note. A flag flip is a manual step for a human, never something you do yourself.

5. Notes that count as evidence

✅ "query_runtime_logs (apps/api, since 2026-10-01T10:02Z, ≥error): 0 entries; list_runtime_errors 40m: 2 groups, both first_seen before deploy (chronic redis timeout, 1d read shows it hourly); smoke 3/3 (re-run 10:41); T-12 GET /api/orders?status=paid → 200 with paid_at field."

❌ "Looks fine, logs clean."

6. Rationalizations (adapted from obra/superpowers)

Common Mistakes

Batch releases with no runtime environment

Most desktop and mobile components have no bound runtime environment at all — there is no host to sample health from, no log stream to query, no error groups to list. That is not an incomplete verification, it is a different one: see batch-artifact-verification for what to check instead (the published artifact, store build, or local run), and say explicitly in the finish_release/rollback_release note that no runtime environment is bound — the same rule as any other gap: never let silence read as a pass.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.