知行多空线指标接入选股与事件回测;大盘总览走 quicksync 统一入口;candles 批量 upsert 分批防 asyncpg 参数超限

This commit is contained in:
2026-09-02 16:51:52 +08:00
parent 6ef8c585d6
commit bec4e8149c
5 changed files with 48 additions and 21 deletions

View File

@@ -60,10 +60,10 @@ def _d(v) -> str | None:
def _get_pro():
if not settings.tushare_token:
raise MarketOverviewError("未配置 TUSHARE_TOKEN无法获取大盘行情backend/.env")
import tushare as ts
# 走统一入口15000 积分档 token 只认 quicksync 镜像(直连 api.tushare.pro 会 40101
from .tushare_provider import get_pro
ts.set_token(settings.tushare_token)
return ts.pro_api()
return get_pro()
def _fetch_index_sync(pro, ts_code: str) -> pd.DataFrame: