PaiGram/core
2023-02-19 20:40:27 +08:00
..
admin 🔥 Remove pymysql 2022-11-30 16:45:53 +08:00
base Support calendar 2023-02-16 16:47:48 +08:00
cookies fix: CookiesNotFoundError when setcookie 2023-01-27 11:50:47 +08:00
game ♻ Refactor ApiHelper 2022-12-10 20:37:43 +08:00
quiz
search Add inline search 2022-12-04 19:56:39 +08:00
sign
template 🎨 Improve config 2022-10-28 15:11:14 +08:00
user 🐛 Fix wrong call of UserService.add_user method 2022-12-01 18:40:02 +08:00
wiki
baseplugin.py 🎨 Simplify Exception Log for clean_message 2022-12-30 16:49:15 +08:00
bot.py 🎨 Update Networking backend tweaks 2023-02-19 20:40:27 +08:00
config.py 🎨 Update Networking backend tweaks 2023-02-19 20:40:27 +08:00
error.py
plugin.py Update Unit Test 2023-02-11 16:29:11 +08:00
README.md
service.py

core 目录说明

关于 Service

服务 Service 需定义在 services 文件夹下, 并继承 core.service.Service

每个 Service 都应包含 startstop 方法, 且这两个方法都为异步方法

from core.service import Service


class TestService(Service):
    def __init__(self):
        """do something"""

    async def start(self, *args, **kwargs):
        """do something"""

    async def stop(self, *args, **kwargs):
        """do something"""