g1331 / xiaomai-bot

以Graia Ariadne框架为基础的战地1QQ机器人
GNU General Public License v3.0
44 stars 6 forks source link

V3 latest #35

Closed g1331 closed 4 months ago

g1331 commented 4 months ago

Summary by Sourcery

This pull request includes multiple enhancements and refactorings across various modules to improve code readability, performance, and maintainability. It also introduces new scripts for setting up and running the project, and removes an obsolete module.

sourcery-ai[bot] commented 4 months ago

Reviewer's Guide by Sourcery

This pull request includes a comprehensive refactor of multiple modules to improve code readability, error handling, and performance. Key changes include the refactoring of channel metadata assignments to use dictionary syntax, simplification of message sending by removing unnecessary line breaks, and optimization of list comprehensions for better readability. Additionally, new modules for sending random Dingzhen and dragon images have been added, and SQLite PRAGMA settings have been introduced for better performance.

File-Level Changes

Files Changes
modules/self_contained/search_image/__init__.py
modules/required/group_manager/__init__.py
modules/self_contained/bf1_info/__init__.py
modules/self_contained/random_wife/__init__.py
modules/required/saya_manager/__init__.py
modules/required/helper/__init__.py
modules/required/perm_manager/__init__.py
modules/required/announcement/__init__.py
modules/self_contained/bf1_servermanager/__init__.py
modules/self_contained/edge_gpt/__init__.py
modules/self_contained/avatar_fun/__init__.py
modules/required/response_manager/__init__.py
modules/self_contained/tarot/__init__.py
modules/self_contained/steam_game_info_searcher/__init__.py
modules/self_contained/av_bt/__init__.py
modules/self_contained/style_picture_generator/__init__.py
modules/self_contained/emoji_mix/__init__.py
modules/required/exception_catcher/__init__.py
modules/required/auto_upgrade/__init__.py
modules/required/chat_recorder/__init__.py
modules/required/self_protect/__init__.py
modules/required/status/__init__.py
modules/self_contained/bf1_join_request_handle/__init__.py
modules/self_contained/bilibili_resolve/__init__.py
modules/self_contained/chat_gpt/__init__.py
modules/self_contained/claude/__init__.py
modules/self_contained/dragon_pic_mute/__init__.py
modules/self_contained/dragon_pic_recall/__init__.py
modules/self_contained/genshin_chara_card/__init__.py
modules/self_contained/github_card/__init__.py
modules/self_contained/ill/__init__.py
modules/self_contained/lolicon_keyword_searcher/__init__.py
modules/self_contained/minicraft_info/__init__.py
modules/self_contained/random_picture/__init__.py
modules/self_contained/the_wondering_earth_counting_down/__init__.py
Refactored channel metadata assignment to use dictionary syntax.
modules/self_contained/search_image/__init__.py
modules/required/group_manager/__init__.py
modules/self_contained/bf1_info/__init__.py
modules/self_contained/random_wife/__init__.py
modules/required/saya_manager/__init__.py
modules/required/helper/__init__.py
modules/required/perm_manager/__init__.py
modules/required/announcement/__init__.py
modules/self_contained/bf1_servermanager/__init__.py
modules/self_contained/edge_gpt/__init__.py
modules/self_contained/avatar_fun/__init__.py
modules/required/response_manager/__init__.py
modules/self_contained/tarot/__init__.py
modules/self_contained/steam_game_info_searcher/__init__.py
modules/self_contained/av_bt/__init__.py
modules/self_contained/style_picture_generator/__init__.py
modules/self_contained/emoji_mix/__init__.py
Simplified message sending by removing unnecessary line breaks.
modules/self_contained/bf1_info/__init__.py
modules/self_contained/random_wife/__init__.py
modules/required/saya_manager/__init__.py
modules/required/helper/__init__.py
modules/self_contained/edge_gpt/__init__.py
modules/self_contained/tarot/__init__.py
modules/self_contained/steam_game_info_searcher/__init__.py
modules/self_contained/style_picture_generator/__init__.py
Optimized list comprehensions for better readability.
modules/self_contained/random_wife/__init__.py
modules/required/perm_manager/__init__.py
modules/required/announcement/__init__.py
modules/self_contained/bf1_servermanager/__init__.py
modules/self_contained/edge_gpt/__init__.py
modules/self_contained/avatar_fun/__init__.py
modules/required/response_manager/__init__.py
modules/self_contained/tarot/__init__.py
modules/self_contained/steam_game_info_searcher/__init__.py
modules/self_contained/av_bt/__init__.py
modules/self_contained/style_picture_generator/__init__.py
Improved error handling and message formatting.

Tips - Trigger a new Sourcery review by commenting `@sourcery-ai review` on the pull request. - Continue your discussion with Sourcery by replying directly to review comments. - You can change your review settings at any time by accessing your [dashboard](https://app.sourcery.ai): - Enable or disable the Sourcery-generated pull request summary or reviewer's guide; - Change the review language; - You can always [contact us](mailto:support@sourcery.ai) if you have any questions or feedback.