Files
python-tools/NdxDailyReport/config.example.yaml
T
wangwei0518 4a592cf457 优化日报脚本网络与路径配置
新增 network.use_environment_proxy 配置项,默认禁用 urllib 对 HTTP_PROXY/HTTPS_PROXY 等环境代理的自动读取,避免代理 CONNECT 连接被重置时影响 Nasdaq、FRED 和 QQBot 请求。

将示例配置中的 state、delivery log 和 runtime log 路径改为相对路径,由脚本按 NdxDailyReport 所在目录解析,方便项目迁移和定时任务部署。

保留真实 config.yaml、state 和投递日志为本地文件,不纳入提交。
2026-06-06 00:26:04 +08:00

38 lines
1.1 KiB
YAML

paths:
state_file: ndx-daily-report-state.json
delivery_log_file: ndx-daily-report-delivery-log.jsonl
runtime_log_file: ndx-daily-report-runtime.log
nasdaq:
quote_api: https://api.nasdaq.com/api/quote/NDX/info?assetclass=index
fred_csv: https://fred.stlouisfed.org/graph/fredgraph.csv?id=NASDAQ100
request_timeout_seconds: 15
network:
# false 表示 urllib 不读取 HTTP_PROXY/HTTPS_PROXY 等环境代理。
# 某些代理会重置 CONNECT 连接,定时脚本默认直连更稳定。
use_environment_proxy: false
qqbot:
appid: "用户填写"
appkey: "用户填写"
token_api: https://bots.qq.com/app/getAppAccessToken
base_api: https://api.sgroup.qq.com
# c2c 表示私聊,group 表示群聊
target_type: "c2c"
# 可选。为空时脚本会尝试从本地 QQBot/Hermes 日志中自动发现。
target_openid: ""
# 自动发现 openid 时的等待时间
auto_discover_timeout_seconds: 60
# 自动发现成功后是否写回 config.yaml
save_discovered_target: true
report:
timezone_trade: America/New_York
timezone_delivery: Asia/Shanghai
replay_on_weekdays: true