Skip to content

Commit adb7886

Browse files
authored
chore(issues): Fix kitchen date parameterization (#93897)
Kitchen format will never begin with "0:". Previously `0:17502` was parameterized as `<date>502` and not `<int>:<int>`.
1 parent 3666547 commit adb7886

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/sentry/grouping/parameterization.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ def compiled_pattern(self) -> re.Pattern[str]:
123123
(\d{4}-?[01]\d-?[0-3]\d\s[0-2]\d:[0-5]\d:[0-5]\d)(\.\d+)?
124124
|
125125
# Kitchen
126-
(\d{1,2}:\d{2}(:\d{2})?(?: [aApP][Mm])?)
126+
([1-9]\d?:\d{2}(:\d{2})?(?: [aApP][Mm])?)
127127
|
128128
# Date
129129
(\d{4}-[01]\d-[0-3]\d)

tests/sentry/grouping/test_parameterization.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,11 @@ def parameterizer():
121121
"""traceparent: 00-0af7651916cd43dd8448eb211c80319c-b7ad6b7169203331-01""",
122122
"""traceparent: <traceparent>""",
123123
),
124+
(
125+
"int - with separator",
126+
"""blah 0:17502 had a problem""",
127+
"""blah <int>:<int> had a problem""",
128+
),
124129
("quoted str", """blah b="1" had a problem""", """blah b=<quoted_str> had a problem"""),
125130
("bool", """blah a=true had a problem""", """blah a=<bool> had a problem"""),
126131
(

0 commit comments

Comments
 (0)