feat: add Hong Kong daily cash execution and dated fees - #17
Merged
Merged
Conversation
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.
港股证券此前会按股票资产类型进入A股规则,错误套用T+1卖出限制和单边印花税。
新增HKDailyExecution日频现金研究接口,复用FixedPoint与ExactAccountLedger,支持显式整手数、按生效日期覆盖的逐项费用、双边印花税取整、同日卖出、T+2收盘解冻卖出款、幂等订单和事务回滚。通用日内规则入口拒绝XHKG/HKEX/SEHK证券,避免冒充已实现港股竞价和盘口撮合。
调用者必须提供独立交收日历及费用政策。新研究仓的示例明确将XHKG交易日用作未经CCASS认证的交收日代理,不据此声称可投资回测。
验证:本地214项测试全部通过;整体覆盖率94.64%;所有既有核心模块纯分支覆盖率≥90%;全仓Ruff及格式检查通过。新增回归覆盖同日买卖、费用舍入、交收现金、整手、禁止卖空、幂等与逐笔账本平衡。