CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

django-migrations

Django migration patterns and safety workflow for PostHog. Use when creating, adjusting, or reviewing Django/Postgres migrations, including non-blocking index/constraint changes, multi-phase schema changes, data backfills, migration conflict rebasing, and product model moves that require SeparateDatabaseAndState. Also use for any deletion or removal of a model, table, column, product, or app — including deleting migration files or retiring a feature — even when no migration is written.

Quality

89%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

—

The risk profile of this skill

SKILL.md
Quality
Evals
Security

Quality

Content

82%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

An unusually strong operational skill: every rule is backed by named commands, helper classes, or CI guards, and risky paths have explicit multi-phase sequences with validation. The residual gaps are minor — a few long prose passages could be trimmed, error-recovery loops are implicit, and some reference-grade detail is inlined in SKILL.md.

Suggestions

Add a brief 'if validation fails' branch to the Workflow section (e.g., what to check when sqlmigrate shows an unexpected DROP DEFAULT or the risk analyzer blocks a migration), making the existing validation steps into true feedback loops.

Tighten the longest prose passages (SafeDropTable deadlock mechanics, Django default= emission behavior) to the load-bearing rule plus a pointer, moving full explanations into safe-django-migrations.md alongside the other deferred detail.

Consider moving the DropForeignKey/DropColumnConstraints operational detail and the cross-language NOT NULL section into the referenced guides with section-anchored pointers, keeping SKILL.md's helper list as a routing table.

DimensionReasoningScore

Conciseness

The body is dense with project-specific, non-inferable knowledge (CI guard names, lock semantics, helper classes) and assumes Django competence — no padding like explaining what a migration is. A few passages could be tightened, e.g., the long prose on SafeDropTable deadlock mechanics and Django default= behavior partly re-states what an experienced model knows, which fits 'efficient; minor instances of over-explanation that could be trimmed' rather than the lean score-5 anchor.

4 / 5

Actionability

Guidance is copy-paste ready throughout: exact commands ('DEBUG=1 ./manage.py makemigrations', './manage.py sqlmigrate <app> <migration_number>', the 'rg -n "INSERT INTO <table>|insertRow…"' grep), named helper operations (SafeAddIndexConcurrently, DropColumnConstraints, untrack_field), and complete executable code blocks for callable choices and db_default. This matches 'fully executable; copy-paste ready code or commands; specific examples cover the common cases'.

5 / 5

Workflow Clarity

The Workflow section gives a clear classify → generate → apply safety rules → validate sequence, destructive operations carry explicit validation (sqlmigrate checks, 'confirm ./manage.py makemigrations --dry-run reports no state drift', audit_orphan_hot_table_fks, deploy-cycle waits), so the destructive-operations cap of 3 does not apply. It sits below the score-5 anchor because explicit error-recovery feedback loops ('if validation fails, do X') are mostly implicit — e.g., what to do when sqlmigrate shows a stray DROP DEFAULT is left to inference.

4 / 5

Progressive Disclosure

No bundle files exist (references/, scripts/, assets/ are absent), and external material is deferred one level deep to clearly signaled repo docs with pinpointed sections — 'Read these files first' lists four docs with exact headings, and repeated pointers like 'Full guide: safe-django-migrations.md (## Dropping Columns)'. This is good structure with minor gaps: some deep inline detail (DropForeignKey/DropColumnConstraints semantics, the cross-language NOT NULL section) is arguably reference material embedded in the overview, which is the score-4 anchor rather than the cleanly split score-5 anchor.

4 / 5

Total

17

/

20

Passed

Description

92%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

A strong description: concrete capability list, explicit dual 'Use when' triggers, and a clearly bounded PostHog-specific niche with minimal conflict risk. The only weakness is slightly less than exhaustive natural-term coverage (no 'PostgreSQL'/'squash' synonyms), keeping trigger term quality at 4.

DimensionReasoningScore

Specificity

The description enumerates multiple concrete capability areas — 'creating, adjusting, or reviewing Django/Postgres migrations, including non-blocking index/constraint changes, multi-phase schema changes, data backfills, migration conflict rebasing, and product model moves that require SeparateDatabaseAndState' — and extends coverage to deletions ('any deletion or removal of a model, table, column, product, or app'). This matches the 'multiple specific concrete actions; comprehensive coverage' anchor rather than the score-4 anchor, which expects minor gaps in coverage; none are evident within the stated domain.

5 / 5

Completeness

It explicitly answers both questions: 'what' ('Django migration patterns and safety workflow for PostHog') and 'when' via two concrete 'Use when'/'Also use for' clauses with specific trigger conditions ('even when no migration is written'). This matches the score-5 example's structure exactly; the score-4 anchor's 'when could be more explicit' does not apply.

5 / 5

Trigger Term Quality

Natural phrases a user would say are well covered: 'Django/Postgres migrations', 'data backfills', 'migration conflict rebasing', 'deleting migration files', 'retiring a feature', 'non-blocking index/constraint changes'. It falls short of the score-5 anchor ('comprehensive coverage of natural terms including synonyms and file extensions') because a few plausible variants are absent — e.g., 'PostgreSQL', 'squash/squashing migrations', 'zero-downtime' — though it clearly exceeds 'a few natural terms missing' being the only gap.

4 / 5

Distinctiveness Conflict Risk

The niche is sharply defined — Django/Postgres migrations specifically for PostHog, with named machinery like SeparateDatabaseAndState — so it is clearly distinguishable from generic Django or database skills. The body even disambiguates the nearest neighbor ('If the task is a ClickHouse migration, use clickhouse-migrations instead'), matching the 'clear niche with distinct triggers; minimal conflict risk' anchor.

5 / 5

Total

19

/

20

Passed

Validation

93%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation — 15 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

relative_links

Relative link issues: 1 suspicious

Warning

Total

15

/

16

Passed

Repository

PostHog/posthog

Path

.agents/skills/django-migrations/SKILL.md

Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.