more logging
This commit is contained in:
parent
e4523b5cb8
commit
fa754bfd76
3
main.py
3
main.py
@ -44,6 +44,7 @@ def format_tags(tags: Iterable[str]):
|
|||||||
|
|
||||||
|
|
||||||
async def send_post(post: E621Post, tag_list: List[str]):
|
async def send_post(post: E621Post, tag_list: List[str]):
|
||||||
|
try:
|
||||||
logging.warning(f'Sending post #{post.id}')
|
logging.warning(f'Sending post #{post.id}')
|
||||||
await bot.send_chat_action(int(os.environ['SEND_CHAT']), action=ChatAction.TYPING)
|
await bot.send_chat_action(int(os.environ['SEND_CHAT']), action=ChatAction.TYPING)
|
||||||
monitored_tags = set(post.tags.flatten()) & set(tag_list)
|
monitored_tags = set(post.tags.flatten()) & set(tag_list)
|
||||||
@ -117,6 +118,8 @@ async def send_post(post: E621Post, tag_list: List[str]):
|
|||||||
await redis.sadd('e621:sent', post.id)
|
await redis.sadd('e621:sent', post.id)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logging.exception(e)
|
logging.exception(e)
|
||||||
|
except Exception as e:
|
||||||
|
logging.exception(e)
|
||||||
|
|
||||||
|
|
||||||
async def check_updates():
|
async def check_updates():
|
||||||
|
Loading…
Reference in New Issue
Block a user