Commit 78891b8
authored
fix(gate): default the three bare gateMode() calls in advisory.ts to advisory (#10245)
recordGateScoreSignals and buildQualityGateWarning called gateMode() bare on
an optional mode field. Since #9167 made gateMode's fallback fail-closed to
"block", an absent slopGateMode resolved to "block" there while
buildSlopGateBlocker (the pure evaluator it's documented to mirror) already
defaulted the same absent value to "advisory" via
gateMode(policy.slopGateMode ?? "advisory") -- so an unconfigured slop gate
still wrote a slop_gate_score corpus signal labeled "mode block" that the
gate itself never evaluated.
Give all three call sites the same ?? "advisory" default and correct the
gateMode doc comment, which claimed every caller already supplied that
default when three sites in the same file didn't.
Co-authored-by: bitfathers94 <237535319+bitfathers94@users.noreply.github.com>1 parent 00e3ee9 commit 78891b8
2 files changed
Lines changed: 29 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1566 | 1566 | | |
1567 | 1567 | | |
1568 | 1568 | | |
1569 | | - | |
| 1569 | + | |
1570 | 1570 | | |
1571 | 1571 | | |
1572 | 1572 | | |
| |||
1586 | 1586 | | |
1587 | 1587 | | |
1588 | 1588 | | |
1589 | | - | |
| 1589 | + | |
1590 | 1590 | | |
1591 | 1591 | | |
1592 | 1592 | | |
| |||
1610 | 1610 | | |
1611 | 1611 | | |
1612 | 1612 | | |
1613 | | - | |
| 1613 | + | |
1614 | 1614 | | |
1615 | 1615 | | |
1616 | 1616 | | |
| |||
1644 | 1644 | | |
1645 | 1645 | | |
1646 | 1646 | | |
1647 | | - | |
1648 | | - | |
| 1647 | + | |
| 1648 | + | |
1649 | 1649 | | |
1650 | 1650 | | |
1651 | 1651 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
331 | 331 | | |
332 | 332 | | |
333 | 333 | | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
334 | 344 | | |
335 | 345 | | |
336 | 346 | | |
| |||
349 | 359 | | |
350 | 360 | | |
351 | 361 | | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
352 | 376 | | |
353 | 377 | | |
354 | 378 | | |
| |||
0 commit comments