Attach strategy plugin metadata#100
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0d297b6502
ℹ️ 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".
| localize_notification_text as _base_localize_notification_text, | ||
| translator_uses_zh as _base_translator_uses_zh, | ||
| ) | ||
| from quant_platform_kit.common.strategy_plugins import attach_strategy_plugin_metadata |
There was a problem hiding this comment.
Update the pinned kit before importing this helper
In the production/Docker path, Dockerfile installs only requirements.txt, which still pins QuantPlatformKit to ceb84a366ed1bf9a53292ff2c73e06b4baac05e2; that pinned quant_platform_kit.common.strategy_plugins does not export attach_strategy_plugin_metadata. Because this import runs while importing application.rebalance_service (and therefore main), the deployed service will fail to start with ImportError before handling any requests unless the QuantPlatformKit pin is bumped to the commit that adds the helper or a compatible fallback is provided.
Useful? React with 👍 / 👎.
Summary:\n- Carry strategy plugin signals through LongBridge runtime config\n- Attach allowed plugin metadata to portfolio snapshots before strategy evaluation\n\nValidation:\n- ./.venv/bin/python -m pytest tests/test_runtime_strategy_adapters.py tests/test_request_handling.py -q\n- ./.venv/bin/python -m ruff check changed files\n- git diff --check HEAD~1..HEAD