From bd2c68118c2c4f5af3e22db9144c53ba7da71d3d Mon Sep 17 00:00:00 2001 From: retoor Date: Fri, 13 Dec 2024 19:54:20 +0100 Subject: [PATCH] Added a few of the bots. --- src/ragnar/bot.py | 2 +- src/ragnar/cli.py | 19 ++++++++++++++----- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/src/ragnar/bot.py b/src/ragnar/bot.py index 21eb9df..4703abf 100644 --- a/src/ragnar/bot.py +++ b/src/ragnar/bot.py @@ -24,7 +24,7 @@ class Bot: "no-spam3": "Nastya", "no-spam4": "Vira", } - self.name = self.names.get(self.name, "everyone") + self.name = self.names.get(self.name, self.username.split("@")[0]) self.mark_text = f"I am {self.name} and downvoted this post because post is considered spam. Your message will be removed from this community site due too much downvotes. See my profile for more information. Read my source code mentioned on my profile to see what you did wrong. Should be no problem for a developer.\n\nHave a nice day!\n\n\nIf the post is not spam, please mention @retoor in the comments of this rant.\n\n@ other ranters downvote this rant to fight spam together! Appearantly there are not enough ragnar bots to downvote this rant, that's why you see this message." self.auth = None self.triggers = [ diff --git a/src/ragnar/cli.py b/src/ragnar/cli.py index 0875417..e894638 100644 --- a/src/ragnar/cli.py +++ b/src/ragnar/cli.py @@ -31,11 +31,20 @@ def bot_task(username, password): def main(): args = parse_args() - with Executor(4) as executor: - for x in range(1, 5): - username = f"no-spam{str(x)}@molodetz.nl" - password = args.password - executor.submit(bot_task, username, password) + with Executor(500) as executor: + usernames = [ + 'no-spam1', + 'no-spam2', + 'no-spam3', + 'no-spam4', + 'no-spam', + 'no-spam2353', + 'no-spam2351', + 'no-spam2350', + 'no-spam2349' + ] + for username in usernames: + executor.submit(bot_task,"{}@molodetz.nl".format(username), args.password) executor.shutdown(wait=True)