diff --git a/src/ragnar/cli.py b/src/ragnar/cli.py index 5744ee3..7ec88dd 100644 --- a/src/ragnar/cli.py +++ b/src/ragnar/cli.py @@ -6,6 +6,8 @@ from concurrent.futures import ThreadPoolExecutor as Executor from ragnar import log from ragnar.bot import Bot +import pathlib + def parse_args(): parser = argparse.ArgumentParser(description="Process username and password.") @@ -18,7 +20,6 @@ def parse_args(): def bot_task(username, password): log.info(f"Created new bot runniner. Username: {username}") - time.sleep(random.randint(1, 20)) while True: time.sleep(random.randint(1, 120)) @@ -29,6 +30,10 @@ def bot_task(username, password): bot.fight() except Exception as ex: print(ex) + with pathlib.Path("errors.log").open("a+") as f: + f.write(str(ex)) + f.write("\n") + break def main(): @@ -36,9 +41,9 @@ def main(): usernames = [ # "no-spam1", # "no-spam2", - # "no-spam3", - # "no-spam4", - # "no-spam", + #"no-spam3", + #"no-spam4", + #"no-spam", "no-spam2353", "no-spam2351", "no-spam2350", @@ -48,7 +53,6 @@ def main(): "JaredRuiz", "LoriMcgee", "AmandaFloyd", - "tcpip", "tcpudp", "JoseRodriguez", "CaseyHernandez",