mirror of
https://github.com/Nezumi-2711/astrbot_plugin_qq_group_daily_analysis.git
synced 2026-09-22 13:38:43 +00:00
fix: 清理TelegramAdapter无用变量并通过lint
This commit is contained in:
@@ -17,6 +17,9 @@ from astrbot.core.message.components import File
|
|||||||
from .src.application.services.analysis_application_service import (
|
from .src.application.services.analysis_application_service import (
|
||||||
AnalysisApplicationService,
|
AnalysisApplicationService,
|
||||||
)
|
)
|
||||||
|
from .src.application.services.message_processing_service import (
|
||||||
|
MessageProcessingService,
|
||||||
|
)
|
||||||
from .src.domain.services.analysis_domain_service import AnalysisDomainService
|
from .src.domain.services.analysis_domain_service import AnalysisDomainService
|
||||||
from .src.domain.services.incremental_merge_service import IncrementalMergeService
|
from .src.domain.services.incremental_merge_service import IncrementalMergeService
|
||||||
from .src.domain.services.statistics_service import StatisticsService
|
from .src.domain.services.statistics_service import StatisticsService
|
||||||
@@ -24,19 +27,15 @@ from .src.infrastructure.analysis.llm_analyzer import LLMAnalyzer
|
|||||||
from .src.infrastructure.config.config_manager import ConfigManager
|
from .src.infrastructure.config.config_manager import ConfigManager
|
||||||
from .src.infrastructure.persistence.history_manager import HistoryManager
|
from .src.infrastructure.persistence.history_manager import HistoryManager
|
||||||
from .src.infrastructure.persistence.incremental_store import IncrementalStore
|
from .src.infrastructure.persistence.incremental_store import IncrementalStore
|
||||||
|
from .src.infrastructure.persistence.telegram_group_registry import (
|
||||||
|
TelegramGroupRegistry,
|
||||||
|
)
|
||||||
from .src.infrastructure.platform.bot_manager import BotManager
|
from .src.infrastructure.platform.bot_manager import BotManager
|
||||||
from .src.infrastructure.reporting.generators import ReportGenerator
|
from .src.infrastructure.reporting.generators import ReportGenerator
|
||||||
from .src.infrastructure.scheduler.auto_scheduler import AutoScheduler
|
from .src.infrastructure.scheduler.auto_scheduler import AutoScheduler
|
||||||
from .src.infrastructure.scheduler.retry import RetryManager
|
from .src.infrastructure.scheduler.retry import RetryManager
|
||||||
from .src.utils.pdf_utils import PDFInstaller
|
from .src.utils.pdf_utils import PDFInstaller
|
||||||
|
|
||||||
from .src.infrastructure.persistence.telegram_group_registry import (
|
|
||||||
TelegramGroupRegistry,
|
|
||||||
)
|
|
||||||
from .src.application.services.message_processing_service import (
|
|
||||||
MessageProcessingService,
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
class QQGroupDailyAnalysis(Star):
|
class QQGroupDailyAnalysis(Star):
|
||||||
"""QQ群日常分析插件主类"""
|
"""QQ群日常分析插件主类"""
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ from collections import Counter
|
|||||||
from astrbot.api.event import AstrMessageEvent
|
from astrbot.api.event import AstrMessageEvent
|
||||||
from astrbot.api.star import Context
|
from astrbot.api.star import Context
|
||||||
|
|
||||||
from ...utils.logger import logger
|
|
||||||
from ...infrastructure.persistence.telegram_group_registry import TelegramGroupRegistry
|
from ...infrastructure.persistence.telegram_group_registry import TelegramGroupRegistry
|
||||||
|
from ...utils.logger import logger
|
||||||
|
|
||||||
|
|
||||||
class MessageProcessingService:
|
class MessageProcessingService:
|
||||||
|
|||||||
@@ -92,7 +92,6 @@ class TelegramAdapter(PlatformAdapter):
|
|||||||
2. 回退:从插件的 KV 存储中获取已知群组 (需注入插件实例)
|
2. 回退:从插件的 KV 存储中获取已知群组 (需注入插件实例)
|
||||||
"""
|
"""
|
||||||
groups = []
|
groups = []
|
||||||
client = self._telegram_client
|
|
||||||
|
|
||||||
# 1. 尝试 API (目前 python-telegram-bot 不支持直接列出所有 chat)
|
# 1. 尝试 API (目前 python-telegram-bot 不支持直接列出所有 chat)
|
||||||
# 如果 client 有扩展方法或未来支持,可在此实现
|
# 如果 client 有扩展方法或未来支持,可在此实现
|
||||||
|
|||||||
Reference in New Issue
Block a user