移除策略级盘后撮合模式

This commit is contained in:
boris
2026-08-27 21:05:57 +08:00
parent dd08358f1c
commit 85c38b0756
4 changed files with 3 additions and 86 deletions
-13
View File
@@ -26,9 +26,6 @@ use crate::strategy::{
TargetPortfolioOrderPricing,
};
pub const POST_CLOSE_FIXED_PRICE_EFFECTIVE_DATE: NaiveDate =
NaiveDate::from_ymd_opt(2026, 7, 6).expect("valid post-close effective date");
#[derive(Debug, Error)]
pub enum BacktestError {
#[error(transparent)]
@@ -1973,16 +1970,6 @@ where
})
.filter(|date| self.config.end_date.map(|end| *date <= end).unwrap_or(true))
.collect::<Vec<_>>();
if self.broker.matching_type() == MatchingType::PostCloseFixedPrice
&& calendar_dates
.first()
.is_some_and(|date| *date < POST_CLOSE_FIXED_PRICE_EFFECTIVE_DATE)
{
return Err(BacktestError::Execution(format!(
"post_close_fixed_price is unavailable before {}",
POST_CLOSE_FIXED_PRICE_EFFECTIVE_DATE
)));
}
let has_decision_inputs = |date: NaiveDate| {
!self.data.factor_snapshot_rows_on(date).is_empty()
&& !self.data.candidate_snapshot_rows_on(date).is_empty()