Skip to content

Commit

Permalink
Merge #140638
Browse files Browse the repository at this point in the history
140638: changefeedccl: skip default collated string locale in changefeed avro r=wenyihu6 a=rharding6373

In TestAvroSchema, we randomly pick column types which may be collated strings. The test panics if the "default" locale is selected for a colated string, so this PR skips that type.

Epic: none
Informs: #140632

Release note: none

Co-authored-by: rharding6373 <[email protected]>
  • Loading branch information
craig[bot] and rharding6373 committed Feb 6, 2025
2 parents 0e31e26 + 4cf44f2 commit 610d7ba
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/ccl/changefeedccl/avro/avro_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -345,9 +345,11 @@ func TestAvroSchema(t *testing.T) {
// "C" and "POSIX" locales are not allowed for collated string
// columns in CRDB (see collatedstring logic tests),
// so we don't expect these types to be emitted by changefeeds.
// TODO(#140632): Reenable "default" locale.
randCollationTag := collationTags[rand.Intn(len(collationTags))]
for randCollationTag == collatedstring.CCollationTag ||
randCollationTag == collatedstring.PosixCollationTag {
randCollationTag == collatedstring.PosixCollationTag ||
randCollationTag == collatedstring.DefaultCollationTag {
randCollationTag = collationTags[rand.Intn(len(collationTags))]
}
collatedType := types.MakeCollatedString(typ, randCollationTag)
Expand Down

0 comments on commit 610d7ba

Please sign in to comment.