Reviews the Postgres migrations a release will run before they reach production – finds the statements that lock or rewrite busy tables (index builds without CONCURRENTLY, NOT NULL columns without defaults, type changes, SET NOT NULL, unvalidated foreign keys and checks, unique constraints.
Reviews the Postgres migrations a release will run before they reach production - finds the statements that lock or rewrite busy tables (index builds without CONCURRENTLY, NOT NULL columns without defaults, type changes, SET NOT NULL, unvalidated foreign keys and checks, unique constraints, unbounded UPDATE/DELETE backfills, renames and drops that the running code still reads), missing down migrations and edited already-applied files, then rehearses them on a throwaway Postgres with production-shaped seed rows, recording the locks each file takes, any table rewrite, and a down/up round trip. Use when someone asks "is this migration safe to run in production", "will this lock the table", "check our migrations before deploy", "can we roll this schema change back", or as the third step of a production readiness review. Do NOT use for a quick lint of one migration you are writing (use zero-downtime-db-migrations), query performance tuning, MySQL or SQLite schemas, or designing a new data model.This is the skill's description: the text your AI reads to decide when the skill applies.
This is the skill's header. The step-by-step instructions are paid content and aren't shown here.
migration-safety/SKILL.md
---
name: migration-safety
description: Reviews the Postgres migrations a release will run before they reach production - finds the statements that lock or rewrite busy tables (index builds without CONCURRENTLY, NOT NULL columns without defaults, type changes, SET NOT NULL, unvalidated foreign keys and checks, unique constraints, unbounded UPDATE/DELETE backfills, renames and drops that the running code still reads), missing down migrations and edited already-applied files, then rehearses them on a throwaway Postgres with production-shaped seed rows, recording the locks each file takes, any table rewrite, and a down/up round trip. Use when someone asks "is this migration safe to run in production", "will this lock the table", "check our migrations before deploy", "can we roll this schema change back", or as the third step of a production readiness review. Do NOT use for a quick lint of one migration you are writing (use zero-downtime-db-migrations), query performance tuning, MySQL or SQLite schemas, or designing a new data model.
---
… the full instructions are part of a premium pack and load in your AI once you have access.