From 4c1cd869303e1407e8d651f11aeffade3b680c52 Mon Sep 17 00:00:00 2001 From: bobloy Date: Mon, 5 Oct 2020 13:06:53 -0400 Subject: [PATCH] Better time keepking doesn't include tick --- timerole/timerole.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/timerole/timerole.py b/timerole/timerole.py index fdfe584..1b56b69 100644 --- a/timerole/timerole.py +++ b/timerole/timerole.py @@ -64,11 +64,12 @@ class Timerole(Cog): Useful for troubleshooting the initial setup """ - pre_run = datetime.utcnow() async with ctx.typing(): + pre_run = datetime.utcnow() await self.timerole_update() + after_run = datetime.utcnow() await ctx.tick() - after_run = datetime.utcnow() + await ctx.maybe_send_embed(f"Took {after_run-pre_run} seconds") @commands.group() @@ -187,7 +188,7 @@ class Timerole(Cog): # all_mrs = await self.config.custom("RoleMember").all() - log.debug(f"Begin timerole update") + # log.debug(f"Begin timerole update") for guild in self.bot.guilds: guild_id = guild.id