feat(douyu): unify account probes and lifecycle writes
Centralize Douyu client creation, CK session probing, identity refresh, role alias resolution, capability persistence, cache and batch throttling across collaboration, fulfillment, tasks and cookie management. Add the account-name copy action in the collaboration table.
This commit is contained in:
@@ -23,6 +23,7 @@ from ..models import (
|
||||
from ..models import (
|
||||
ProxyConfig as ProxyConfigModel,
|
||||
)
|
||||
from .douyu_account_probe import activity_client
|
||||
from .douyu_goods_service import upsert_goods_snapshot
|
||||
from .douyu_service import (
|
||||
DOUYU_CONFIG_FIELDS,
|
||||
@@ -411,9 +412,9 @@ class DouyuBatchRunnerCore:
|
||||
def _client(self, cookie: str) -> DouyuActivityClient:
|
||||
"""任务 HTTP 客户端:写操作任务注入会话级代理(兑换/锁单/支付/充值/送礼),
|
||||
读操作任务直连;见 DOUYU_PROXY_TASK_TYPES。"""
|
||||
return DouyuActivityClient(
|
||||
return activity_client(
|
||||
cookie,
|
||||
logger=lambda msg: self._push_log("debug", msg),
|
||||
logger_callback=lambda msg: self._push_log("debug", msg),
|
||||
proxies=self._proxies_for_task(),
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user