PamGram/core
2024-06-19 23:23:45 +08:00
..
dependence Support starrail action log 2024-06-18 00:29:31 +08:00
handler Support Ignore unbound user command in group 2024-03-25 20:43:11 +08:00
plugin Support Ignore unbound user command in group 2024-03-25 20:43:11 +08:00
services Support starrail challenge boss 2024-06-19 23:23:45 +08:00
__init__.py
application.py
base_service.py
basemodel.py
config.py
error.py 💄 Format with black 24.x.x 2024-03-16 18:43:20 +08:00
README.md

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"""