mirror of
https://github.com/suyiiyii/nonebot-bison.git
synced 2025-06-04 02:26:11 +08:00
Merge branch 'main' into arknights
This commit is contained in:
commit
af01c73f8d
@ -51,7 +51,7 @@ async def fetch_and_send(target_type: str):
|
|||||||
bot = bot_list[0] if bot_list else None
|
bot = bot_list[0] if bot_list else None
|
||||||
for new_post in new_posts:
|
for new_post in new_posts:
|
||||||
logger.warning('get new {} dynamic: {}'.format(target_type, new_post.url))
|
logger.warning('get new {} dynamic: {}'.format(target_type, new_post.url))
|
||||||
logger.warning(new_post[:50])
|
logger.warning(new_post)
|
||||||
if not bot:
|
if not bot:
|
||||||
logger.warning('no bot connected')
|
logger.warning('no bot connected')
|
||||||
else:
|
else:
|
||||||
|
@ -31,4 +31,4 @@ class Post:
|
|||||||
self.pics = pics
|
self.pics = pics
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
return 'type: {}\ntext: {}\nurl: {}\npic: {}'.format(self.target_type, self.text, self.url, ','.join(self.pics))
|
return 'type: {}\ntext: {}\nurl: {}\npic: {}'.format(self.target_type, self.text[:50], self.url, ','.join(map(lambda x: 'b64img' if x.startswith('base64') else x, self.pics)))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user