We're assuming that validating the regex against RE2 with re.Compile would be OK when we made the type:repo behavior change, but the newest discovery is that (?i:pattern) syntax is OK for re.Compile but not for PSQL. We should check this up front, so that we can decide whether to run a repo search, and/or warn. But throwing hard errors is no bueno.
We throw hard errors for these patterns:
repo:(?i:sup)
(?i:sup) type:repo
We're assuming that validating the regex against RE2 with
re.Compile
would be OK when we made thetype:repo
behavior change, but the newest discovery is that(?i:pattern)
syntax is OK forre.Compile
but not for PSQL. We should check this up front, so that we can decide whether to run a repo search, and/or warn. But throwing hard errors is no bueno.