trading_agent.doctor.checks.telegram_pairing_check
¶
Checks that a phone is paired, so alerts can reach the user away from the computer.
Typical usage example:
result = TelegramPairingCheck(enabled, store).run()
TelegramPairingCheck
¶
Bases: DoctorCheck
Counts the paired Telegram chats.
Creates the check.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
enabled
|
bool
|
Whether [telegram] is enabled. |
required |
store
|
PairingStore
|
The pairing file. |
required |
Source code in src/trading_agent/doctor/checks/telegram_pairing_check.py
run
¶
Counts paired chats.
Returns:
| Type | Description |
|---|---|
CheckResult
|
OK when Telegram is on with a paired chat; a warning otherwise, since going live without it is allowed but alerts then reach only the web page. |