Enable M5 auto-scan alerts and remove live dashboard

M5 already broadcast through the shared _scan_timeframe path but was
documented as data-only (docstring, CLAUDE.md, DOCUMENTATION.md, plus a
phantom `if tf == M5: return` step that never existed in code). Align all
docs/comments so M5 alerting at C+ grade is the intended, documented behavior.

Remove the live dashboard entirely per request: the 30s refresh loop,
per-scan refresh, boot send, and the dashboard-only stats layer
(_signal_stats / _stats_updated / _update_signal_stats and its call sites,
_format_stats_dashboard and its helper constants). Drop now-unused ZoneInfo
import and dashboard mentions from help/autoscan/boot messages and the test
suite. The WebSocket level-breach monitor and level cache are untouched.

Tests: 136 passed, 0 failed.
This commit is contained in:
Harwinder
2026-05-20 12:45:27 -04:00
parent cc53448c34
commit c46bb85012
4 changed files with 12 additions and 183 deletions
-11
View File
@@ -1322,7 +1322,6 @@ from telegram_bot import (
_escape_md, _signal_label, _mtf_line,
format_signal_message, _format_scan_summary,
_seconds_until_boundary, _check_level_breach,
_format_stats_dashboard,
scan_keyboard, SCAN_BUTTONS, SCAN_LOOKUP,
_update_level_cache, _last_prices, _level_cache, _level_cache_ts,
_WS_TO_PAIR,
@@ -1529,16 +1528,6 @@ def _():
assert _WS_TO_PAIR["XAU/USD"] == XAUUSD
@test("_format_stats_dashboard returns waiting message when empty")
def _():
import telegram_bot
old_stats = telegram_bot._signal_stats.copy()
telegram_bot._signal_stats.clear()
text = _format_stats_dashboard()
assert "Waiting" in text or "waiting" in text.lower()
telegram_bot._signal_stats.update(old_stats)
# ══════════════════════════════════════════════════════════════════════
# MODULE 8: Integration / Cross-module tests
# ══════════════════════════════════════════════════════════════════════