Bu5hm4nn
6bcf78e5df
style: format UI files and remove lint excludes
...
- Remove app/components/ and app/pages/ from ruff/black excludes
- Pre-commit reformatted multi-line strings for consistency
- All files now follow the same code style
2026-04-01 13:55:55 +02:00
Bu5hm4nn
f9ea7f0b67
fix: address PR review issues for event comparison and backtests
...
Critical fixes:
- Add validate_and_calculate_units() helper with proper error handling
- Handle division by zero for entry_spot in refresh_preview() and render_report()
- Add server-side validation for initial_value > 0
- Add try/except for derive_entry_spot() to handle fixture source limitations
Important improvements:
- Add dynamic default dates with get_default_backtest_dates()
- Add validate_date_range_for_symbol() for symbol-specific date bounds
- Add SYMBOL_MIN_DATES validation for backtests
- Update date_range_hint based on selected symbol
Tests:
- Add test_page_validation.py with 21 tests for:
- validate_and_calculate_units edge cases
- validate_date_range_for_symbol bounds checking
- get_default_backtest_dates dynamic generation
- SYMBOL_MIN_DATES constant verification
2026-03-29 18:45:29 +02:00
Bu5hm4nn
853c80d3a2
feat(event-comparison): use initial portfolio value instead of underlying units
...
- Changed UI input from 'Underlying units' to 'Initial portfolio value ($)'
- Underlying units are now calculated as initial_value / entry_spot
- Updated default value to workspace gold_value instead of gold_ounces * entry_spot
- Result summary now shows both 'Initial value' and 'Underlying units'
- This allows users to specify how much they invest on day 1, and the system
automatically calculates the maximum purchasable shares/contracts
2026-03-29 16:12:33 +02:00
Bu5hm4nn
477514f838
feat(BT-002): add historical snapshot provider
2026-03-27 18:31:28 +01:00
Bu5hm4nn
3c9ff201e1
feat(BT-003B): add event comparison drilldown
2026-03-26 22:05:31 +01:00
Bu5hm4nn
f38d0a53a9
refactor(pre-alpha): fail closed on historical preview fallbacks
2026-03-26 11:55:45 +01:00
Bu5hm4nn
4eec0127da
fix(UX-001): reconcile preview validation behavior
2026-03-26 10:39:03 +01:00
Bu5hm4nn
82e52f7162
fix(UX-001): tighten historical stale state handling
2026-03-26 10:32:05 +01:00
Bu5hm4nn
78de8782c4
fix(UX-001): address layout review findings
2026-03-26 10:24:52 +01:00
Bu5hm4nn
a60c5fb1f2
feat(UX-001): add full-width two-pane dashboard layout
2026-03-25 23:19:09 +01:00
Bu5hm4nn
87900b01bf
fix(CORE-002C): align historical units with workspace weight
2026-03-25 21:37:55 +01:00
Bu5hm4nn
132aaed512
feat(CORE-001D1): harden unit-aware workspace persistence
2026-03-25 13:19:33 +01:00
Bu5hm4nn
40f7e74a1b
feat(SEC-001): protect workspace bootstrap with turnstile
2026-03-25 10:02:10 +01:00
Bu5hm4nn
c7c8654be7
feat(CORE-001C): type historical unit materialization
2026-03-24 22:30:36 +01:00
Bu5hm4nn
5ac66ea97b
feat(PORT-004C): seed workspace routes from portfolio settings
2026-03-24 21:14:09 +01:00
Bu5hm4nn
ff4e565ee6
feat(BT-003A): add event comparison page
2026-03-24 19:20:35 +01:00