(reason, restore=False, **extra)
| 1748 | v2_metrics = {} |
| 1749 | |
| 1750 | def _skip(reason, restore=False, **extra): |
| 1751 | if restore: |
| 1752 | restore_unreviewed_stop_state(session_id, touched_paths, snap_baseline) |
| 1753 | # CC truncates metrics to 10 keys by |
| 1754 | # insertion order. v2_metrics (3) must precede sweep (3) so the v2 |
| 1755 | # diagnostics survive when extra adds touched_paths_count + ip_* keys. |
| 1756 | emit_metrics({ |
| 1757 | "skipped": True, "skip_reason": reason, "fire_index": fire_count + 1, |
| 1758 | "diff_strategy_v2": True, |
| 1759 | **v2_metrics, **extra, **sweep, |
| 1760 | }) |
| 1761 | sys.exit(0) |
| 1762 | |
| 1763 | # Limit stop hook firings per asyncRewake loop to prevent infinite loops. |
| 1764 | # fire_count auto-expires after STOP_LOOP_STATE_TTL_SEC so a stale count |
no test coverage detected