From d27975b6a56d3b3e12c181fc44615ce41bda42d8 Mon Sep 17 00:00:00 2001 From: "2569718930@qq.com" <2569718930@qq.com> Date: Wed, 4 Mar 2026 22:52:06 +0800 Subject: [PATCH] feat: Add Turkish flag emoji to MGM temperature displays and integrate MGM daily forecasts into future forecast messages. --- bot_listener.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/bot_listener.py b/bot_listener.py index f9dab39d..5bcaefc2 100644 --- a/bot_listener.py +++ b/bot_listener.py @@ -411,9 +411,9 @@ def start_bot(): if mgm_high is not None: sources.append("MGM") comp_parts.append( - f"MGM: {mgm_high:.1f}{temp_symbol}" + f"πŸ‡ΉπŸ‡· MGM: {mgm_high:.1f}{temp_symbol}" if isinstance(mgm_high, (int, float)) - else f"MGM: {mgm_high}" + else f"πŸ‡ΉπŸ‡· MGM: {mgm_high}" ) # ζ£€ζŸ₯ζ˜―ε¦ζœ‰ζ˜Ύθ‘—εˆ†ζ­§ (θΆ…θΏ‡ 5Β°F ζˆ– 2.5Β°C) @@ -437,8 +437,16 @@ def start_bot(): # 明后倩 if len(dates) > 1: future_forecasts = [] + mgm_daily = mgm.get("daily_forecasts", {}) or {} for d, t in zip(dates[1:], max_temps[1:]): - future_forecasts.append(f"{d[5:]}: {t}{temp_symbol}") + # ζ£€ζŸ₯ MGM ζ˜―ε¦ζœ‰θ―₯ζ—₯ζœŸηš„ι’„ζŠ₯ + mgm_f = mgm_daily.get(d) + if mgm_f is not None: + future_forecasts.append( + f"{d[5:]}: {t}{temp_symbol} | πŸ‡ΉπŸ‡· MGM: {mgm_f}{temp_symbol}" + ) + else: + future_forecasts.append(f"{d[5:]}: {t}{temp_symbol}") msg_lines.append("πŸ“… " + " | ".join(future_forecasts)) # --- 3.5 ζ—₯ε‡Ίζ—₯落 + ζ—₯η…§ζ—Άι•Ώ ---