Skip to content

feat(risk): RuntimeRiskLimits and completed-session daily bars - #604

Merged
Pigbibi merged 2 commits into
mainfrom
fix/runtime-risk-limits-20260917
Sep 16, 2026
Merged

Pigbibi merged 2 commits into
mainfrom
fix/runtime-risk-limits-20260917

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add explicit RuntimeRiskLimits capability so trusted platform configs can authorize the approved SOXL multi-ETF exposure caps without relaxing the default single-position gate.
  • Map LongPort naive candlestick timestamps via process-local time onto completed XNYS sessions (DST / UTC / NY / Shanghai covered in tests).
  • Regression coverage for 8-ETF full nominal budget approve/reject, missing limits falling back to legacy single-position rejection, and invalid limits fail-closed.

Test plan

  • .venv/bin/python -m pytest tests/test_risk_gate.py tests/test_longbridge_market_data.py -q → 108 passed, 393 subtests
  • CI on this PR
  • After merge: UES pin/lock to this SHA, then Schwab risk-binding PR

Made with Cursor

Pigbibi and others added 2 commits September 17, 2026 05:17
Enable trusted multi-ETF exposure caps for SOXL recovery without weakening
the default single-position gate, and map LongPort naive timestamps via
process-local time to completed XNYS sessions.

Co-authored-by: Cursor <cursoragent@cursor.com>
Fixture as_of dates aged past max_age_days on wall-clock CI after 2026-09-14,
parking cycles as observation_stale unrelated to RuntimeRiskLimits.

Co-authored-by: Cursor <cursoragent@cursor.com>
@Pigbibi
Pigbibi merged commit 68c5159 into main Sep 16, 2026
1 check passed
@Pigbibi
Pigbibi deleted the fix/runtime-risk-limits-20260917 branch September 16, 2026 21:28
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