MG21 — BEGIN/START issued inside an open transaction
Group: Migration safety · Auto-fixable: no
A BEGIN/START while a transaction is already open nests: Postgres ignores the inner BEGIN and the next COMMIT ends the outer transaction early, which is rarely intended.
Example
Section titled “Example”bad: BEGIN; BEGIN; COMMIT; COMMIT;good: BEGIN; COMMIT;Configure
Section titled “Configure”Disable this rule in banshee.toml:
[lint]exclude = ["MG21"]Or silence one line with -- noqa: MG21. See Linting.