Skip to content

fix: resolve strategy aliases from the generated display source - #1002

Merged
Pigbibi merged 2 commits into
mainfrom
fix/strategy-alias-single-source-20261031
Oct 31, 2026
Merged

Pigbibi merged 2 commits into
mainfrom
fix/strategy-alias-single-source-20261031

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Oct 31, 2026

Copy link
Copy Markdown
Contributor

AI assistance

Qoder agent, owner-authorized session.

What changed

  • validate_runtime_target_strategy_policy kept a two-entry alias map while display-names.config.json defines three aliases. bitcoin_etf_smart_dca therefore resolved to itself and bypassed the domain, allowed-execution-mode and frozen-profile checks.
  • Both the Python validator and the console Worker now read the generated alias map (display_names.json / display_names_data.js), so aliases have one source.
  • Added a regression test proving an alias cannot skip the platform domain check.

No generated projections were hand-edited; build_display_names.py --check stays clean.

How verified

  • python3 python/scripts/build_display_names.py --check — match.
  • python3 python/scripts/build_config.py --check — pass.
  • python3 python/scripts/runtime_settings.py validate — pass.
  • python3 -m unittest discover -s python/tests — 994 passed, 11 failures are pre-existing macOS mapfile/bash-3.2 shell-script failures unrelated to this change.
  • python3 -m unittest -v python.tests.test_frozen_selection python.tests.test_runtime_settings python.tests.test_runtime_stop — 203 passed.
  • node tests/frozen_strategy_selection_validation.mjs, node tests/strategy_switch_worker_validation.mjs, node tests/console_runtime_state_validation.mjs — pass.
  • python3 scripts/check_style.py — 0 blocking, 1 pre-existing README advisory.

runtime_settings and the console Worker each kept a two-entry alias
literal while the display config defines three, so bitcoin_etf_smart_dca
resolved to itself and skipped domain, allowed-mode and frozen checks.
Read the generated alias map in both places and cover the bypass with a
regression test.
@Pigbibi Pigbibi added the owner-approved Owner approval for high-risk PRs. AI agents must never apply this label. label Oct 31, 2026
@Pigbibi
Pigbibi merged commit 6100487 into main Oct 31, 2026
16 checks passed
@Pigbibi
Pigbibi deleted the fix/strategy-alias-single-source-20261031 branch October 31, 2026 15:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

owner-approved Owner approval for high-risk PRs. AI agents must never apply this label.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant