Commit e3364bd
chore: simplify counting, severity, IoU, and filter helpers without behavior change
Inline _query_param_filters into alert_filters (helper was called in exactly
one place). Tighten serialize() to use isinstance(value, (datetime, date))
instead of duck-typing hasattr(value, "isoformat"); behavior is identical for
all psycopg2-returned types. Add date to the datetime import accordingly.
Static equivalence verified for all filter combinations and all DB-returned
types including datetime, date, int, str, bool, Decimal, timedelta, and None.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 8b872a1 commit e3364bd
1 file changed
Lines changed: 10 additions & 22 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
157 | 157 | | |
158 | 158 | | |
159 | 159 | | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | | - | |
165 | | - | |
166 | | - | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
167 | 164 | | |
168 | 165 | | |
169 | 166 | | |
| |||
200 | 197 | | |
201 | 198 | | |
202 | 199 | | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | 200 | | |
215 | 201 | | |
216 | 202 | | |
| |||
220 | 206 | | |
221 | 207 | | |
222 | 208 | | |
223 | | - | |
224 | | - | |
225 | | - | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
226 | 214 | | |
227 | 215 | | |
228 | 216 | | |
| |||
0 commit comments