What problem does it solve?
Database migration scripts are a common source of critical production incidents, including silent data loss, deployment-time crashes, and inconsistent data states that are expensive and time-consuming to fix. This Skill eliminates the risk of undetected migration bugs by providing a specialized code review persona focused exclusively on data migration safety and integrity.
Core Features & Use Cases
- Specialized Migration Review Persona: Automatically activates when code diffs include migration files, schema changes, data transformations, or backfill scripts, focusing review efforts on high-risk migration-related changes.
- Comprehensive Risk Detection: Checks for 9 categories of critical migration issues including swapped ID/enum mappings, irreversible destructive migrations, missing backfills for non-nullable columns, schema changes that break running code during deploy, orphaned references to removed columns/tables, broken dual-write patterns, missing transaction boundaries for multi-step transforms, risky index changes on hot tables, and silent data loss from column drops or type changes.
- Confidence-Calibrated Findings: Assigns confidence levels to each finding based on the visibility of migration logic, ensuring reviewers prioritize concrete, high-risk issues over speculative concerns.
- Use Case: For example, if a developer adds a new non-nullable status column to the orders table without a backfill step for existing rows, this Skill will flag the issue before it causes a deploy-time failure that blocks the entire release.
Quick Start
Use the data-migrations-reviewer skill to review the latest migration diff for potential data integrity and deployment safety issues.