diff --git a/Makefile b/Makefile index 74078ec..c110877 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,6 @@ ENV=./.venv/bin/activate PYTHON=./.venv/bin/python +BIN=./.venv/bin all: ensure_env format build install test format: @@ -17,7 +18,7 @@ install: $(PYTHON) -m pip install -e . run: - $(PYTHON) -m ragnar.run + $(BIN)/ragnar.run test: $(PYTHON) -m unittest ragnar.tests diff --git a/README.md b/README.md index f013a46..785df2e 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,10 @@ Another one: ![Image generated by Buffon](buffon2.jpg) +Third one, the legendary bot war of 2024 ended in peace. + +![Image generated by Buffon](buffon3.jpg) + ## How they work One process starts many bots. These bots look at new rants. diff --git a/buffon3.jpg b/buffon3.jpg new file mode 100644 index 0000000..90430df Binary files /dev/null and b/buffon3.jpg differ diff --git a/dist/Ragnar-1.3.37-py3-none-any.whl b/dist/Ragnar-1.3.37-py3-none-any.whl index 9d76e3b..830178a 100644 Binary files a/dist/Ragnar-1.3.37-py3-none-any.whl and b/dist/Ragnar-1.3.37-py3-none-any.whl differ diff --git a/dist/ragnar-1.3.37.tar.gz b/dist/ragnar-1.3.37.tar.gz index 0aee956..3301dc1 100644 Binary files a/dist/ragnar-1.3.37.tar.gz and b/dist/ragnar-1.3.37.tar.gz differ diff --git a/src/Ragnar.egg-info/SOURCES.txt b/src/Ragnar.egg-info/SOURCES.txt index 739cf95..013dffc 100644 --- a/src/Ragnar.egg-info/SOURCES.txt +++ b/src/Ragnar.egg-info/SOURCES.txt @@ -13,5 +13,6 @@ src/ragnar/api.py src/ragnar/bot.py src/ragnar/cache.py src/ragnar/cli.py +src/ragnar/victoria.py src/ragnar/tests/__init__.py src/ragnar/tests/bot.py \ No newline at end of file diff --git a/src/ragnar/cli.py b/src/ragnar/cli.py index c40b2d2..88b5f24 100644 --- a/src/ragnar/cli.py +++ b/src/ragnar/cli.py @@ -5,7 +5,7 @@ from concurrent.futures import ThreadPoolExecutor as Executor from ragnar import log from ragnar.bot import Bot - +from ragnar.victoria import vic def parse_args(): parser = argparse.ArgumentParser(description="Process username and password.") @@ -30,30 +30,7 @@ def bot_task(username, password): def main(): args = parse_args() - usernames = [ - # "no-spam1", - # "no-spam2", - # "no-spam3", - # "no-spam4", - # "no-spam", - "no-spam2353", - "no-spam2351", - "no-spam2350", - "no-spam2349", - "JamesMedina", - "MichelleWeeks", - "JaredRuiz", - "LoriMcgee", - "AmandaFloyd", - "tcpudp", - "JoseRodriguez", - "CaseyHernandez", - "ToddHarris", - "AnneRose", - "GregoryBowman", - "LeahVasquez", - "JamesMedina", - ] + usernames = vic.get_friends() with Executor(len(usernames)) as executor: for username in usernames: diff --git a/src/ragnar/victoria.py b/src/ragnar/victoria.py new file mode 100644 index 0000000..176fd6f --- /dev/null +++ b/src/ragnar/victoria.py @@ -0,0 +1,3 @@ +from xmlrpc.client import ServerProxy + +vic = ServerProxy("https://victoria.molodetz.nl/rpc")