Skip to content

Commit

Permalink
sqlsmith: add crdb_internal.job_payload_type to blocklist
Browse files Browse the repository at this point in the history
Previously, we would test the `crdb_internal.job_payload_type` builtin
function with random values. Since this function unmarshals a jobspb.Payload,
calling it with random bytes will always produce an error. We do not need
to test this function under the smither.

Epic: none
Fixes: cockroachdb#93843

Release note: None
  • Loading branch information
jayshrivastava committed Dec 20, 2022
1 parent 6eddf3e commit f20c0b7
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/internal/sqlsmith/schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -513,6 +513,9 @@ var functions = func() map[tree.FunctionClass]map[oid.Oid][]function {
"crdb_internal.revalidate_unique_constraint",
"crdb_internal.request_statement_bundle",
"crdb_internal.set_compaction_concurrency",
// crdb_internal.job_payload_type unmarshals a jobspb.Payload from
// raw bytes. Calling it with random values will produce an error.
"crdb_internal.job_payload_type",
} {
skip = skip || strings.Contains(def.Name, substr)
}
Expand Down

0 comments on commit f20c0b7

Please sign in to comment.