Skip to content

[codex] Route runtime errors to main bot#141

Merged
Pigbibi merged 1 commit into
mainfrom
codex/runtime-errors-main-bot-strategy-plugin-alerts
Jun 4, 2026
Merged

[codex] Route runtime errors to main bot#141
Pigbibi merged 1 commit into
mainfrom
codex/runtime-errors-main-bot-strategy-plugin-alerts

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • send runtime failure notifications only to the platform main Telegram bot
  • rename strategy plugin alert runtime settings to STRATEGY_PLUGIN_ALERT
  • sync Cloud Run env workflow to publish new names and remove old CRISIS_ALERT plugin envs
  • pin quant-platform-kit to 3b6a0a9bedde72773e188041e0dc48516b38aadc

Validation

  • env PYTHONPATH=.:../QuantPlatformKit/src:../UsEquityStrategies/src:../HkEquityStrategies/src /tmp/codex-alert-test-venv/bin/python -m pytest -q tests/test_request_handling.py tests/test_runtime_config_support.py
  • bash tests/test_sync_cloud_run_env_workflow.sh

@Pigbibi Pigbibi merged commit e12a328 into main Jun 4, 2026
1 check failed
@Pigbibi Pigbibi deleted the codex/runtime-errors-main-bot-strategy-plugin-alerts branch June 4, 2026 05:04

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5686a1ad97

ℹ️ 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".

Comment thread runtime_config_support.py
crisis_alert_channels=split_env_list(os.getenv("CRISIS_ALERT_CHANNELS")),
crisis_alert_email_recipients=split_env_list(
os.getenv("CRISIS_ALERT_EMAIL_RECIPIENTS")
strategy_plugin_alert_channels=split_env_list(os.getenv("STRATEGY_PLUGIN_ALERT_CHANNELS")),

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Preserve legacy alert settings during the rename

When a deployed service, or the Cloud Run env-sync workflow before repository vars/secrets are manually renamed, still has the previous CRISIS_ALERT_* settings, this loader now ignores them and returns empty strategy-plugin alert configuration because it only reads STRATEGY_PLUGIN_ALERT_*. Since the workflow also removes the old Cloud Run names, existing alert channels/tokens/chat IDs are silently dropped on the first deploy; keeping a fallback to the old env names during the migration would prevent strategy-plugin alert delivery from being disabled.

Useful? React with 👍 / 👎.

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