squawk-cli
Linter for PostgreSQL migrations
Decision gist · record as of 2026-08-14
Yes. Squawk is actively maintained, has no known vulnerabilities, and fills a specific niche—preventing downtime from unsafe Postgres migrations. The permissive dual license and multi-platform binaries lower adoption friction. Install if your team runs Postgres migrations and wants automated guardrails; skip if you do not use Postgres or migrations are rare.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python >=3.8.
- Pre-built binaries available for macOS (Intel/ARM), Linux (x86_64/aarch64), and Windows; source builds require Rust.
- Medium install friction due to compiled Rust binaries, but pre-built wheels exist for common platforms (macOS x86_64/arm64, Linux x86_64/aarch64, Windows).
License · maintenance · safety
Apache-2.0 OR MIT (permissive) — Dual-licensed under Apache-2.0 OR MIT (permissive). You may choose either license; no restrictions on commercial or private use.
last release 2026-08-06 (8 days) · last repo commit 2026-08-13 · 1,153 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 520,481 downloads/mo, #6,210 on PyPI
Alternatives
Verify before relying
pip install squawk-cli
squawk example.sql
# or check stdin: squawk --stdin-filepath=migration.sql < migration.sql- How many built-in rules are available and what is their coverage of common migration anti-patterns.
- Performance on large SQL files or migration batches.
- Integration maturity with CI/CD systems beyond GitHub Actions.
What it is and what it does
Squawk is a linter that parses PostgreSQL SQL and migration files to identify patterns that commonly cause production issues: unsafe index creation, lock-prone constraint additions, serial-type pitfalls, and schema changes that block reads or writes. It runs as a CLI tool and outputs warnings with inline suggestions and remediation examples.
The tool supports multiple reporting formats (TTY, JSON, GitLab, GCC), rule exclusion via CLI flags or `.squawk.toml` config files, and inline SQL comments to suppress specific checks. It integrates with pre-commit hooks, GitHub Actions, and VSCode, making it suitable for catching migration problems before they reach production.
Use it for
- Review migration files in CI/CD to catch blocking operations (e.g., UNIQUE constraints, index creation) before deployment.
- Enforce team standards on column types (e.g., prefer bigint over serial, text over varchar with length limits).
- Suppress known-safe violations per-file or per-rule via comments or config, reducing noise in large legacy codebases.
- Local pre-commit hook to validate SQL syntax and schema safety before pushing to version control.
- Generate structured JSON reports for custom tooling or dashboards that track migration risk over time.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Squawk is actively maintained, has no known vulnerabilities, and fills a specific niche—preventing downtime from unsafe Postgres migrations. The permissive dual license and multi-platform binaries lower adoption friction. Install if your team runs Postgres migrations and wants automated guardrails; skip if you do not use Postgres or migrations are rare.
Install
squawk-cli on PyPI
Before you install
Medium install friction due to compiled Rust binaries, but pre-built wheels exist for common platforms (macOS x86_64/arm64, Linux x86_64/aarch64, Windows). Last release 8 days ago; active maintenance with 1153 GitHub stars.
Requires Python >=3.8. Pre-built binaries available for macOS (Intel/ARM), Linux (x86_64/aarch64), and Windows; source builds require Rust.
License in practice
Dual-licensed under Apache-2.0 OR MIT (permissive). You may choose either license; no restrictions on commercial or private use.
Quickstart
pip install squawk-cli
squawk example.sql
# or check stdin: squawk --stdin-filepath=migration.sql < migration.sql
Verify before relying
- How many built-in rules are available and what is their coverage of common migration anti-patterns.
- Performance on large SQL files or migration batches.
- Integration maturity with CI/CD systems beyond GitHub Actions.
Package facts
| License | Apache-2.0 OR MIT permissive |
| Python support | Supports the current Python release >=3.8 |
| Install friction | Medium. Platform-specific wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 8 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 520,481 / month, #6,210 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | License :: OSI Approved :: Apache Software LicenseLicense :: OSI Approved :: MIT LicenseOperating System :: MacOSOperating System :: Microsoft :: WindowsOperating System :: POSIX :: LinuxProgramming Language :: Python :: 3Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPyProgramming Language :: Rust |
Evidence: squawk_cli-2.62.0-py3-none-macosx_10_12_x86_64.whl; squawk_cli-2.62.0-py3-none-macosx_11_0_arm64.whl; squawk_cli-2.62.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; squawk_cli-2.62.0-py3-none-manylinux_2_28_x86_64.whl; squawk_cli-2.62.0-py3-none-win32.whl; squawk_cli-2.62.0-py3-none-win_amd64.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “postgres migration linter”
- squawk-cliLinter that analyzes PostgreSQL migrations and SQL statements to…
- django-pgmigratePrevents migration downtime by detecting and terminating blocking…
- django-pg-migration-toolsProvides safer, production-ready Django migration operations for…
Give your agent the search over MCP, or paste the wish link into any chat.
More Quality Assurance packages
Coverage.py measures which lines of Python code are executed during test runs, reporting coverage percentages and identifying untested code paths.
Install it if you want to measure test completeness or enforce coverage thresholds in your project.
Ruff is a Python linter and code formatter written in Rust that combines linting, formatting, and code fixing into a single tool, replacing Flake8, Black, isort, and related utilities.
Pexpect spawns and controls interactive console applications by sending input and matching output patterns, automating tasks that would otherwise require manual interaction.
Black reformats Python source code to a consistent style by parsing entire files and rewriting them according to an opinionated, deterministic set of rules, eliminating manual formatting decisions.
pytest-xdist distributes pytest tests across multiple CPU cores or machines to speed up test execution, with the simplest usage being `pytest -n auto` to spawn workers equal to available CPUs.
Install it if your test suite takes long enough that parallelization would save meaningful time.
Validates AWS CloudFormation templates in YAML or JSON format against resource provider schemas and best practices, checking property values and configuration correctness.
Install it if you work with CloudFormation templates.
See also django-pg-zero-downtime-migrations · migra · pgsanity · django-pg-migration-tools · django-migration-linter · django-pgmigrate · collate-sqlfluff · sqlfluff · sqlfluffrs · pglast