Skip to content

Correct timing book accounting and published artifacts - #3

Merged
PureSaber merged 1 commit into
mainfrom
codex/correct-timing-accounting-20261001
Oct 1, 2026
Merged

PureSaber merged 1 commit into
mainfrom
codex/correct-timing-accounting-20261001

Conversation

@PureSaber

Copy link
Copy Markdown
Owner

Timing studies could price returns, costs, and exported orders from different position paths, and futures cash settlement and decision-day alignment were inconsistent.

Changes:

  • use one drift-aware trade path for portfolio returns, transaction costs, and order deltas
  • debit fees from cash, settle futures P&L, and require valuations for active contracts
  • align style drawdown attribution to prior decision weights
  • publish close pre-trade positions plus explicit return weights and cost units
  • stage standard artifacts atomically and refuse to overwrite non-empty destinations
  • add accounting and export regressions and update the research contract

Validation:

  • python -m ruff check src tests
  • python -m ruff format --check src tests
  • python -m pytest -q: 64 passed
  • explicit coverage run: 64 passed, 84% coverage

Known test signal:
The suite emits pandas FutureWarnings from existing fillna behavior in overlay/style code; all tests pass and those warnings are outside this accounting fix.

@PureSaber PureSaber left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

独立代码审查:74755de2166d1d9c318531089329a578d3c09aba

已独立核对前期决策收益、价格与费用漂移、期货现金结算、估值价格来源、成交数量守恒及暂存验证后目录发布。64项完整测试通过;缺失活跃期货价格、验证失败和并发占用目标目录的回归可阻止部分发布。return_weight与期末持仓权重分开,有真实生产端至报告对账证据。未发现阻塞问题。

此为独立agent代码审查记录;合并仍须通过该提交的全部CI与仓库required checks,不替代或绕过GitHub保护规则。

@PureSaber
PureSaber merged commit 36ec230 into main Oct 1, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant