unchecked-do-block
warningUnchecked DO block
Why it's unsafe
This DO block contains dynamic SQL (EXECUTE) or a body pgsafe could not parse; the rest of the block was checked, but that part was not.
Safe rewrite
Move the dynamic DDL/DML out of the DO block into top-level statements so pgsafe can check it, or suppress this finding with an inline -- pgsafe:ignore unchecked-do-block <reason> after review.
Example
Try it in the playground →Unsafe
DO $$ BEGIN EXECUTE 'ALTER TABLE users ADD COLUMN x int'; END $$;