[codex] guard crypto equity combo exits and rotation config#56
Conversation
Co-Authored-By: Codex <noreply@openai.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 091b4657ef
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| zscore_exit_allow_outside_execution_window=bool( | ||
| config.get("zscore_exit_allow_outside_execution_window", True) |
There was a problem hiding this comment.
Forward the strategy date into the DCA overlay
When zscore_exit_allow_outside_execution_window is set to False, the downstream BTC DCA plan decides whether the Z-score overlay is in-window from its as_of argument (kwargs.get("as_of")); this entrypoint now forwards the flag but still never forwards ctx.as_of, so the DCA code falls back to the wall-clock date. Backtests/replays or delayed evaluations can therefore skip or apply the combo BTC exit based on today rather than the StrategyContext date; pass as_of=ctx.as_of with the DCA-related kwargs.
Useful? React with 👍 / 👎.
Summary
Test Plan
PYTHONPATH=src:/Users/lisiyi/Projects/QuantPlatformKit/src python3 -m pytest -q testspython3 -m ruff check .PYTHONPATH=/Users/lisiyi/Projects/QuantPlatformKit/src:/Users/lisiyi/Projects/CryptoStrategies/src python3 -m pytest -q tests/test_runtime_config_support.py tests/test_strategy_loader.py tests/test_strategy_runtime.py tests/test_notify_i18n.pyin BinancePlatformPYTHONPATH=src:scripts python3 scripts/research_crypto_combo_backtest.py --json-output