From bbe1c0aec688196373a962724bbb645e80abb2b0 Mon Sep 17 00:00:00 2001 From: Gabriella Date: Mon, 22 Dec 2025 11:01:28 -0600 Subject: [PATCH] Add break readout for the bot-aux --- src/py/bot_aux.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/py/bot_aux.py b/src/py/bot_aux.py index 66b54bc..8a8355d 100644 --- a/src/py/bot_aux.py +++ b/src/py/bot_aux.py @@ -36,11 +36,22 @@ async def on_ready(): print(f'{client.user} has connected.') print(args.guild_id) + guild: discord.Guild = client.get_guild(args.guild_id) channel: discord.TextChannel = guild.get_channel(args.channel_id) + callouts = DATABASE_CONN.query_callouts(NUMBER_OF_DAYS) formatted_callouts = DATABASE_CONN.formatted_list_of_callouts(callouts) output = f'Callouts for the next {NUMBER_OF_DAYS} days:\n' + formatted_callouts + output += '\n\n' + + output += f'Breaks for the next {NUMBER_OF_DAYS} days:\n' + + breaks: str = DATABASE_CONN.query_breaks(NUMBER_OF_DAYS) + formatted_breaks: str = DATABASE_CONN.formatted_list_of_breaks(breaks) + + output += formatted_breaks + await channel.send(output) await client.close() # Another way to exit, a little bit cleaner than exit(0) return