Commit 4a642c3
committed
feat(logs): source-categorized logging (EVENTS/SYS/NODE) + events.log + filters
Every log line now gets one category at the source:
- classifyLogCategory(msg) in server.js (EVENTS→SYS→NODE, first match wins),
mirrored byte-identically as logCategory(msg) in admin.html.
- broadcast() sets data.cat before emit (logBuffer stays string[]; replayed init
lines are re-classified client-side with the same rules).
- EVENTS lines persist to results/events.log (separate from the per-run test log),
1-file rotation at ~2MB. The pipeline's per-run audit.log now tees only
non-events lines, so EVENTS (lifecycle) and the run's SYS+NODE stream are kept
separate on disk, as requested.
- admin Live Log gets ALL/EVENTS/SYS/NODE filter buttons (mirrors /live), each row
tagged data-cat (server cat for live lines, re-derived for replay).
Adversarially reviewed (no CRITICAL/HIGH; mechanism — data.cat mutation reaches
the pipeline wrapper, rotation safety, server↔client classifier identity — all
verified). Applied the two MEDIUM classifier fixes the review found: dropped bare
'💾' from EVENTS (it caught the per-node "💾 Cached:" line, mis-routing it to
events.log and dropping it from the run log; 'Saved' already covers the lifecycle
lines), and added 'Resuming Test' to EVENTS. Test suite green (188/31/45/35).1 parent 09774a4 commit 4a642c3
3 files changed
Lines changed: 113 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
572 | 572 | | |
573 | 573 | | |
574 | 574 | | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
575 | 589 | | |
576 | 590 | | |
577 | 591 | | |
| |||
1073 | 1087 | | |
1074 | 1088 | | |
1075 | 1089 | | |
| 1090 | + | |
| 1091 | + | |
| 1092 | + | |
| 1093 | + | |
| 1094 | + | |
| 1095 | + | |
1076 | 1096 | | |
1077 | 1097 | | |
1078 | 1098 | | |
| |||
1440 | 1460 | | |
1441 | 1461 | | |
1442 | 1462 | | |
1443 | | - | |
| 1463 | + | |
| 1464 | + | |
1444 | 1465 | | |
1445 | 1466 | | |
1446 | 1467 | | |
| |||
2036 | 2057 | | |
2037 | 2058 | | |
2038 | 2059 | | |
2039 | | - | |
| 2060 | + | |
| 2061 | + | |
| 2062 | + | |
| 2063 | + | |
| 2064 | + | |
| 2065 | + | |
| 2066 | + | |
| 2067 | + | |
| 2068 | + | |
| 2069 | + | |
| 2070 | + | |
| 2071 | + | |
| 2072 | + | |
| 2073 | + | |
| 2074 | + | |
| 2075 | + | |
| 2076 | + | |
| 2077 | + | |
| 2078 | + | |
| 2079 | + | |
| 2080 | + | |
| 2081 | + | |
| 2082 | + | |
| 2083 | + | |
| 2084 | + | |
| 2085 | + | |
| 2086 | + | |
| 2087 | + | |
| 2088 | + | |
| 2089 | + | |
| 2090 | + | |
| 2091 | + | |
| 2092 | + | |
| 2093 | + | |
| 2094 | + | |
| 2095 | + | |
| 2096 | + | |
2040 | 2097 | | |
2041 | 2098 | | |
2042 | 2099 | | |
2043 | 2100 | | |
2044 | 2101 | | |
2045 | 2102 | | |
2046 | 2103 | | |
| 2104 | + | |
2047 | 2105 | | |
2048 | 2106 | | |
2049 | 2107 | | |
2050 | 2108 | | |
| 2109 | + | |
2051 | 2110 | | |
2052 | 2111 | | |
2053 | 2112 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
592 | 592 | | |
593 | 593 | | |
594 | 594 | | |
595 | | - | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
596 | 599 | | |
597 | 600 | | |
598 | 601 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
285 | 285 | | |
286 | 286 | | |
287 | 287 | | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
288 | 329 | | |
289 | 330 | | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
290 | 335 | | |
291 | 336 | | |
| 337 | + | |
292 | 338 | | |
293 | 339 | | |
294 | 340 | | |
| |||
509 | 555 | | |
510 | 556 | | |
511 | 557 | | |
512 | | - | |
| 558 | + | |
513 | 559 | | |
514 | 560 | | |
515 | 561 | | |
| |||
1812 | 1858 | | |
1813 | 1859 | | |
1814 | 1860 | | |
| 1861 | + | |
1815 | 1862 | | |
1816 | 1863 | | |
1817 | 1864 | | |
| |||
0 commit comments