From 0a86020e70f00b9f4b0f2387e619cead3ac8f133 Mon Sep 17 00:00:00 2001 From: benx1n <1119809439@qq.com> Date: Wed, 15 Nov 2023 18:21:16 +0800 Subject: [PATCH] =?UTF-8?q?[=F0=9F=9A=80]update=201.0.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bot.py | 42 +++++++++++++++--------------- pyproject.toml | 4 +-- src/plugins/hikari_bot/__init__.py | 2 +- 3 files changed, 24 insertions(+), 24 deletions(-) diff --git a/bot.py b/bot.py index bf7aa51..cb1cb4e 100644 --- a/bot.py +++ b/bot.py @@ -16,40 +16,40 @@ config.nb2_path = Path(__file__).parent -if __name__ == "__mp_main__" or ("run" in sys.argv and "nb" in sys.argv[0]): +if __name__ == '__mp_main__' or ('run' in sys.argv and 'nb' in sys.argv[0]): logger.add( - "logs/error.log", - rotation="00:00", - retention="1 week", + 'logs/error.log', + rotation='00:00', + retention='1 week', diagnose=False, - level="ERROR", + level='ERROR', format=default_format, - encoding="utf-8", + encoding='utf-8', ) logger.add( - "logs/info.log", - rotation="00:00", - retention="1 week", + 'logs/info.log', + rotation='00:00', + retention='1 week', diagnose=False, - level="INFO", + level='INFO', format=default_format, - encoding="utf-8", + encoding='utf-8', ) logger.add( - "logs/warning.log", - rotation="00:00", - retention="1 week", + 'logs/warning.log', + rotation='00:00', + retention='1 week', diagnose=False, - level="WARNING", + level='WARNING', format=default_format, - encoding="utf-8", + encoding='utf-8', ) if driver.config.use_plugin_go_cqhttp: - nonebot.load_plugin("nonebot_plugin_gocqhttp") - nonebot.load_from_toml("pyproject.toml") + nonebot.load_plugin('nonebot_plugin_gocqhttp') + nonebot.load_from_toml('pyproject.toml') # ... -if __name__ == "__main__": +if __name__ == '__main__': # logger.warning("Always use `nb run` to start the bot instead of manually running!") - nonebot.load_plugin("nonebot_plugin_reboot") - nonebot.run(app="__mp_main__:app") + nonebot.load_plugin('nonebot_plugin_reboot') + nonebot.run(app='__mp_main__:app') diff --git a/pyproject.toml b/pyproject.toml index 032e8ff..c323aef 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "hikari-bot" -version = "1.0.2.1" +version = "1.0.3" description = "Nonebot2 HikariBot,支持战舰世界水表查询" authors = ["benx1n "] license = "MIT" @@ -14,7 +14,7 @@ packages = [ [tool.poetry.dependencies] python = "^3.8.0" -nonebot2 = { version = "^2.0.1", extras = ["fastapi"] } +nonebot2 = { version = "^2.1.0", extras = ["httpx", "websockets", "fastapi"] } nonebot-adapter-onebot = "^2.1.0" nonebot-plugin-apscheduler = "^0.2.0" nonebot_plugin_guild_patch = "^0.2.1" diff --git a/src/plugins/hikari_bot/__init__.py b/src/plugins/hikari_bot/__init__.py index 81ec49b..7519f5b 100644 --- a/src/plugins/hikari_bot/__init__.py +++ b/src/plugins/hikari_bot/__init__.py @@ -44,7 +44,7 @@ is_first_run = True _nlmt = DailyNumberLimiter(_max) _flmt = FreqLimiter(3) -__bot_version__ = '1.0.2.1' +__bot_version__ = '1.0.3' bot_get_random_pic = on_fullmatch('wws 随机表情包', block=True, priority=5) bot_update = on_fullmatch('wws 更新Hikari', priority=5, block=True, permission=SUPERUSER)