handle deprecation of assert_block safely