supabase / splinter

Supabase Postgres Linter
https://supabase.github.io/splinter/
68 stars 6 forks source link

Lint for non-immutable check constraints #57

Open darora opened 2 months ago

darora commented 2 months ago

A common failure mode of restores or other similar workflows is for a database to contain check constraints that are not immutable. This is not supported by Postgres, but not flagged when such a constraint is created: https://www.postgresql.org/docs/current/ddl-constraints.html#DDL-CONSTRAINTS-CHECK-CONSTRAINTS

It would be great if we can flag the existence of such constraints.