diff --git a/src/main.py b/src/main.py index 5fd9db9..5ae3913 100755 --- a/src/main.py +++ b/src/main.py @@ -20,7 +20,7 @@ import os import sys import argparse import signal -import common +import FediBot import contextlib import yanlib import fnmatch @@ -67,7 +67,7 @@ def get_list_of_hashes_with_profiles(f_name, profiles, profile_default): return [YanBotHash(i, get_profile(i, profiles, profile_default)) for i in yanlib.get_hash_list(f_name)] -class YandereBot(common.YandereBot): +class YandereBot(FediBot.YandereBot): listPictures = [] lenBlacklist = 0 @@ -173,7 +173,7 @@ class YandereBot(common.YandereBot): try: return super(YandereBot, self).post(picked) # Attempted to post a file that doesn't exist (immediately repost ignoring retry_seconds) - except (FileNotFoundError, common.InvalidPost): + except (FileNotFoundError, FediBot.InvalidPost): print("File not found:", picked.get_hash_path()) reinsert_image = False @@ -282,11 +282,11 @@ if __name__ == "__main__": except FailedToLoadCfg: sys.exit(6) # Exceptions raised from the bot - except common.Debug: + except FediBot.Debug: sys.exit(5) - except common.BadCfgFile: + except FediBot.BadCfgFile: sys.exit(4) except BadPostSettings: sys.exit(3) - except common.FailedLogin: + except FediBot.FailedLogin: sys.exit(2)