-
Notifications
You must be signed in to change notification settings - Fork 0
Align US strategy lifecycle gates #205
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -108,6 +108,11 @@ | |
| available_capabilities=frozenset({"fractional_share_execution"}), | ||
| runtime_policy=StrategyRuntimePolicy(signal_effective_after_trading_days=0), | ||
| ), | ||
| } | ||
|
|
||
| # Shadow/internal combo profiles remain describable for runtime contract and | ||
| # test coverage, but they are not treated as base live adapters. | ||
| SHADOW_RUNTIME_ADAPTERS: dict[str, StrategyRuntimeAdapter] = { | ||
| US_EQUITY_COMBO_PROFILE: StrategyRuntimeAdapter( | ||
| status_icon="\U0001f1fa\U0001f1f8", | ||
| available_inputs=frozenset({"russell_snapshot", "current_holdings"}), | ||
|
|
@@ -183,6 +188,18 @@ def _build_platform_runtime_adapter_map(platform_id: str) -> dict[str, StrategyR | |
| profile, | ||
| platform_id=normalized_platform, | ||
| ) | ||
| for profile, base_adapter in SHADOW_RUNTIME_ADAPTERS.items(): | ||
| definition = get_strategy_definition(profile) | ||
| if normalized_platform not in definition.supported_platforms: | ||
| continue | ||
| adapters[profile] = validate_strategy_runtime_adapter( | ||
| replace( | ||
| base_adapter, | ||
| available_inputs=frozenset(base_adapter.available_inputs or definition.required_inputs), | ||
| portfolio_input_name=base_adapter.portfolio_input_name | ||
| or ("portfolio_snapshot" if "portfolio_snapshot" in definition.required_inputs else None), | ||
|
Comment on lines
+198
to
+200
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
For the shadow combo profiles on Schwab, Longbridge, and Firstrade, this new adapter path skips the cross-target-mode normalization done in Useful? React with 👍 / 👎. |
||
| ) | ||
| ) | ||
| return adapters | ||
|
|
||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In contexts that load
us_equity_combo_entrypointdirectly, this catalog demotion is not reflected because the entrypoint is still constructed fromcombo_manifests.us_equity_combo_manifest, whose description continues to label the profile as live and whose default config has no shadow marker. A manifest-driven platform or operator UI can therefore still surfaceus_equity_comboas live even thoughget_runtime_enabled_profiles()now excludes it; please update the combo manifest alongside this status change.Useful? React with 👍 / 👎.