fix: SyntaxError in _send_daily_forecast behoben

This commit is contained in:
Homelab Cursor 2026-03-21 13:46:32 +01:00
parent 822c980c15
commit 5b37b6ef5c

View file

@ -832,16 +832,12 @@ async def _send_daily_forecast(context):
report = await asyncio.get_event_loop().run_in_executor(None, handle_get_health_forecast) report = await asyncio.get_event_loop().run_in_executor(None, handle_get_health_forecast)
prompt = ( prompt = (
"Morgendlicher System-Check. Analysiere diesen Report und gib eine kurze " "Morgendlicher System-Check. Analysiere diesen Report und gib eine kurze "
"Prognose (max 10 Zeilen) ob sich Probleme anbahnen. Nenne nur echte Auffälligkeiten, " "Prognose ob sich Probleme anbahnen. Nur echte Auffaelligkeiten nennen, "
"gib klare Handlungsempfehlungen wenn nötig. Wenn alles OK ist, reicht eine kurze Entwarnung. "klare Handlungsempfehlung wenn noetig. Bei allem OK: kurze Entwarnung."
"\n\n" + report
"
+ report
) )
analysis = await asyncio.get_event_loop().run_in_executor(None, ask_with_tools, prompt) analysis = await asyncio.get_event_loop().run_in_executor(None, ask_with_tools, prompt)
msg = f"🔭 *Tägliche Systemvorhersage* msg = "🔭 *Taegliche Systemvorhersage*\n\n" + analysis
{analysis}"
await bot.send_message(chat_id=CHAT_ID, text=msg, parse_mode="Markdown") await bot.send_message(chat_id=CHAT_ID, text=msg, parse_mode="Markdown")
log.info("Taegl. Systemvorhersage gesendet") log.info("Taegl. Systemvorhersage gesendet")
except Exception: except Exception: