From 4c53f4c1745a9dc3196bc7f67dd048cd6bf04ce7 Mon Sep 17 00:00:00 2001 From: David Grieser Date: Tue, 7 Jan 2025 14:26:14 +0100 Subject: [PATCH] Ignore slackbot. --- bot.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bot.py b/bot.py index ec6a915..29b3ff6 100644 --- a/bot.py +++ b/bot.py @@ -201,7 +201,10 @@ async def update_user_cache(app: AsyncApp) -> None: response = await app.client.users_list() users = response['members'] for user in users: - if not user.get('deleted') and not user.get('is_bot', False) and not user.get("is_restricted", False): + if not user.get('deleted') and \ + not user.get('is_bot', False) and \ + not user.get('is_restricted', False) and \ + user.get('id', '') != 'USLACKBOT': user_id = user.get('id', '') user_name = normalize_id(user.get('name', '')) user_name_normalized = normalize_user_name(user_name)