Skip to content

Commit 85f2325

Browse files
authored
Merge pull request #258 from hrnciar/python3.15
Fix re.Scanner capturing group for Python 3.15 compatibility
2 parents d28a8cb + 24675f8 commit 85f2325

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎patsy/constraint.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ def _tokenize_constraint(string, variable_names):
187187
lparen_re = r"\("
188188
rparen_re = r"\)"
189189
op_re = "|".join([re.escape(op.token_type) for op in _ops])
190-
num_re = r"[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?"
190+
num_re = r"[-+]?[0-9]*\.?[0-9]+(?:[eE][-+]?[0-9]+)?"
191191
whitespace_re = r"\s+"
192192

193193
# Prefer long matches:

0 commit comments

Comments
 (0)