From 4c04d0f0eacb6659b5d226a085c8520dce1a8859 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Fri, 12 Jan 2024 12:42:33 +0000 Subject: [PATCH] Block some ai crawlers --- crawlers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crawlers.py b/crawlers.py index 9176a22b2..dac88b15f 100644 --- a/crawlers.py +++ b/crawlers.py @@ -127,7 +127,7 @@ def blocked_user_agent(calling_domain: str, agent_str: str, # unless this is a news instance or if it is in the allowed list bot_strings = ('bot/', 'bot-', '/bot', '/robot', 'gptbot', '-ai/', ' ai/', '-ai ', ' ai ', 'spider/', - 'externalhit/') + 'externalhit/', 'chatgpt') contains_bot_string = False for bot_str in bot_strings: if bot_str in agent_str_lower: