fix(polymarket): _PARTY_RE: add Republicans? plural support for symmetry
CI/CD / build-and-push (push) Successful in 2m24s
CI/CD / build-and-push (push) Successful in 2m24s
Republicans (plural) previously didn't match _PARTY_RE because the pattern was r"\bRepublican\b" (no optional s). Added Republicans? for symmetry with Democrats?. The general-election family fix already handles this case via etype_m, but the plural match is needed for the party-only fallback branch. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -42,7 +42,7 @@ _US_STATE_RE = re.compile(
|
||||
r"West\s+Virginia|Wisconsin|Wyoming)\b",
|
||||
re.IGNORECASE,
|
||||
)
|
||||
_PARTY_RE = re.compile(r"\b(Republican|Democrats?|Democratic|GOP)\b", re.IGNORECASE)
|
||||
_PARTY_RE = re.compile(r"\b(Republicans?|Democrats?|Democratic|GOP)\b", re.IGNORECASE)
|
||||
_ELECTION_TYPE_RE = re.compile(
|
||||
r"\b(presidential|president|mayoral|mayor|gubernatorial|governor|"
|
||||
r"senate|congress(?:ional)?|primary|election)\b",
|
||||
|
||||
Reference in New Issue
Block a user