Skip to content

feat(risk): add stamp_consecutive_losses_on_snapshot helper#211

Merged
Pigbibi merged 1 commit into
mainfrom
feat/stamp-consecutive-losses-helper
Jul 9, 2026
Merged

feat(risk): add stamp_consecutive_losses_on_snapshot helper#211
Pigbibi merged 1 commit into
mainfrom
feat/stamp-consecutive-losses-helper

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add stamp_consecutive_losses_on_snapshot() for platform runtimes
  • Best-effort: preserves explicit metadata, never raises
  • Used by Schwab / LongBridge / Firstrade / Binance / QMT wire-up

Test plan

  • python3 -m unittest tests.test_live_return_collector -v
  • CI green

Made with Cursor

Shared best-effort helper for platforms to stamp trailing loss streak
onto portfolio metadata before strategy evaluate.

Co-Authored-By: Claude <noreply@anthropic.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@cursor

cursor Bot commented Jul 9, 2026

Copy link
Copy Markdown

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

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