Repository navigation
feat(notifications): opt-in unified digest without trading dependency upgrades - #597
Merged
Merged
Conversation
…hanges Co-Authored-By: Codex <noreply@openai.com>
…d JSON boundary Co-Authored-By: Codex <noreply@openai.com>
…d orders Co-Authored-By: Codex <noreply@openai.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
仅修改通知:在现有 QSL_ROUTINE_NOTIFICATION_MODE=daily_digest 下,把确认完成的常规交易归入统一日报;健康无交易项静默,失败、未决订单、风险、认证和持久化异常保留即时通知。QSL_DIGEST_ROUTINE_ORDERS=false 可保留普通订单即时通知。默认模式不变。
已有私有报告增加通知事实,既有监测入口按完整窗口生成候选;支持按配置证明非交易窗口。没有新增交易调度、启用账户、部署、应用变量或读写密钥。
保留现有 QPK、策略、UES 与锁文件。通知小模块取自已注明的 QPK 精确源码,放入现有 notifications 包,避免顺带升级交易依赖。
验证:共享路由/候选测试及平台通知接线回归、Ruff、actionlint 与 whitespace 检查;远端 CI 仍须以当前 head 为准。合成中英预览 delivered=false,未发送真实消息。
精确 head:97968002ef4d84e178ccd7d19bc291f79f28464e
交易差异审查见本 PR 的 docs/unified-notification-trading-diff-review.zh-CN.md。以下为本次作者自审,不声称独立审查。只有当前 head 的 CI 全绿,审查无问题,且重新核对 push/workflow_run 不会部署时才合并;否则保持草稿。
交易差异审查:LongBridgePlatform
审查方式:本次作者自审,辅以 AST 调用参数比较;不声称独立人工审查。
基线:
a0de99314ebd15fcfc7f3e99de3b54dbb924cb7c。范围为当前 PR 相对基线的全部改动。结论:源码差异仅涉及通知路由、附加的通知报告事实、已有监测入口的候选投影、通知配置透传、测试和说明。交易依赖、锁文件、UES/QPK pin、信号、仓位、资金限额、订单构造、券商调用、状态 claim 和风险门禁保持原样。
现有文件中的券商、订单、风险、交易状态和报告持久化调用,已对调用表达式及全部参数做 AST 比较:
application/rebalance_service.pymain.py新增模块不调用券商。只有既有云监测器在
daily_digest且目标明确启用时,才读已有私有报告并写候选;不启用账户、不修改订单或交易排程。关闭模式保持既有行为。失败、未决订单、风险、认证及持久化问题保留即时通知;已确认的普通订单可通过QSL_DIGEST_ROUTINE_ORDERS=false继续即时发送。通知代码取自 QPK
4cc5e55251269923771f90cd661bb62a5cfdf0cd,有意不升级平台交易依赖。三个源文件逐字节相同:digest_routing.py60c3f258c4d1a03bc49c7d03b392c02c316541726dfacb0b1d4fae6dbd2e5017digest_candidates.py6272c0ca16ee63eecd9bcb25870df7f575d8fac3f487d3ab1ac69cc3831042a0digest_archive.pyb9a92299adfddff42c62f7d493845e0cbde91df7e475a5cb6bf2114446045b49合并条件:相关验证通过、PR 当前精确 head 的 CI 全绿、当前远端主线的 push / workflow_run / 可复用 workflow 调用链无自动部署。否则保留草稿。此审查不批准从旧生产 revision 升级到整个当前主线;生产到候选的完整差异、UES 指纹与 baseline 仍须按后续发布方案单独审查。