fix(backtest): improve error message for dates outside fixture window
- Add helpful message suggesting Databento/Yahoo Finance for dates outside fixture range - Update test to expect BOUNDED policy for backtest UI
This commit is contained in:
@@ -54,7 +54,8 @@ class SharedHistoricalFixtureSource:
|
||||
if start_date < self.start_date or end_date > self.end_date:
|
||||
raise ValueError(
|
||||
f"{self.feature_label} deterministic fixture data only supports the seeded "
|
||||
f"{self.start_date.isoformat()} through {self.end_date.isoformat()} window"
|
||||
f"{self.start_date.isoformat()} through {self.end_date.isoformat()} window. "
|
||||
f"For dates outside this range, please use Databento or Yahoo Finance data source."
|
||||
)
|
||||
return [point for point in self.history if start_date <= point.date <= end_date]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user