fix(data): ak-weekly 断路器饿死修复=_safe_northbound_em+类型调序 [vps]——09-05 03:00 首跑 rc=2 根因:akshare stock_hsgt_individual_em 对无北向数据标的(~1117/2883,301xxx 等)在 data_json[result][pages] 抛 TypeError NoneType not subscriptable→failed→30 连败断路器→跳过后续类型,share_capital/top_holders/gdhs 全饿死(gdhs 目录至今不存在);端点健康(600519 返 1683 行,09-06 晨复测);修=①_safe_northbound_em 子串匹配 not subscriptable 返空 df 带 9 列 schema→走无北向持仓 empty 写空+done 既定语义不耗重试/断路器(同 _safe_top_10_em 手法)②weekly wrapper 调序 gdhs,share_capital,top_holders,northbound 最大最险者殿后防再连累③顺手 BOM;TDD 2 新测先红后绿+217 全绿;双脚本已 scp 生效位+Parse/py_compile 预检过;gdhs 手动补跑另行 [vps]
CI/CD / test (push) Successful in 23s
CI/CD / nas-deploy (push) Successful in 7s
CI/CD / nas-verify (push) Successful in 13s

This commit is contained in:
2026-09-06 08:29:58 +08:00
parent c728f2368c
commit 694a0d2238
3 changed files with 73 additions and 5 deletions
+5 -3
View File
@@ -1,5 +1,7 @@
# ak_stock_wrapper.ps1 — sanguo-ak-weekly schtask wrapper (weekly 周六03:00 akshare per-stock 慢)
# northbound+share_capital+top_holders+gdhs --force; per-stock 全量慢, 周末夜间;
# ak_stock_wrapper.ps1 — sanguo-ak-weekly schtask wrapper (weekly 周六03:00 akshare per-stock 慢)
# --force 全量刷新; 顺序=gdhs,share_capital,top_holders,northbound (09-06 调序:
# 09-05 northbound 1117/2883 无数据标的连败触发断路器, 饿死后续 3 类型——
# 最大最险的 northbound 挪最后, 即使再断路也不连累前面);
# gdhs=股东户数 per-period 全市场单次 (09-02 入列, 披露守卫>90天季度末, marker 去重无新期零网络)
$env:http_proxy = ''
$env:https_proxy = ''
@@ -9,5 +11,5 @@ $ts = Get-Date -Format 'yyyyMMdd_HHmmss'
$logDir = 'C:\sanguo_vnpy_v2\data\migration_logs'
if (-not (Test-Path $logDir)) { New-Item -ItemType Directory -Path $logDir -Force | Out-Null }
$log = Join-Path $logDir "ak_stock_$ts.txt"
C:\Python310\python.exe -X utf8 C:\sanguo_vnpy_v2\scripts\data_platform\akshare_static_download.py --types northbound,share_capital,top_holders,gdhs --force *>> $log
C:\Python310\python.exe -X utf8 C:\sanguo_vnpy_v2\scripts\data_platform\akshare_static_download.py --types gdhs,share_capital,top_holders,northbound --force *>> $log
exit $LASTEXITCODE