diff options
| author | 2024-06-01 17:27:13 +0100 | |
|---|---|---|
| committer | 2024-06-01 17:27:13 +0100 | |
| commit | 5a29befbc90929551299a7994cb1c9e2f6e014dd (patch) | |
| tree | 838b25e6eab386874c0f62e71d0b7943c6526c21 | |
| parent | Increase accuracy of the system infomration parser (diff) | |
Allow users to prepare prior to sending positive feedback
| -rw-r--r-- | arthur/exts/systems/system_information.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/arthur/exts/systems/system_information.py b/arthur/exts/systems/system_information.py index 0e8c844..a5c460d 100644 --- a/arthur/exts/systems/system_information.py +++ b/arthur/exts/systems/system_information.py @@ -1,5 +1,6 @@ """Return system information on our production 9front infrastructure.""" +import asyncio import random from datetime import datetime @@ -83,14 +84,14 @@ class SystemInformation(Cog): if random.random() < msg_thresh: logger.trace("Criteria hit, generating comment.") - blogcom = await self.fetch_blogcom() comment = lib9front.generate_blog_comment(blogcom).strip() - await msg.reply(f"{comment} {random.choice(CORPORATE_FRIENDLY_SMILEYS)}") - self.last_sent = datetime.utcnow() + async with msg.channel.typing(): + await asyncio.sleep(3) + await msg.reply(f"{comment} {random.choice(CORPORATE_FRIENDLY_SMILEYS)}") @command(name="software") async def software(self, ctx: Context) -> None: |