🚀 MAJOR FIX: Parallel agents eliminate 330+ compilation errors
- Fixed all FromPrimitive imports across codebase - Resolved all common::types import paths (219+ files) - Fixed Volume constructor issues (type alias vs struct) - Resolved all E0308 type mismatches - Fixed ExecutionReport and BrokerError imports - Added missing Price arithmetic assignment traits - Fixed Decimal to_f64 method calls with ToPrimitive - Eliminated all re-exports per architectural rules Errors reduced from 436 to 106 - 76% reduction achieved
This commit is contained in:
@@ -12,7 +12,7 @@ use std::io::Write;
|
||||
use std::time::Duration;
|
||||
use tempfile::NamedTempFile;
|
||||
use tokio::runtime::Runtime;
|
||||
use common::types::*;
|
||||
use common::*;
|
||||
|
||||
use backtesting::{
|
||||
replay_engine::{DataFormat, DataSource, MarketReplay, ReplayConfig, SourceType},
|
||||
|
||||
@@ -61,7 +61,7 @@ use serde::{Deserialize, Serialize};
|
||||
use tokio::sync::{mpsc, RwLock};
|
||||
use tracing::{error, info, warn};
|
||||
|
||||
use common::types::*;
|
||||
use common::*;
|
||||
|
||||
// mod types; // Removed - using core::prelude types instead
|
||||
|
||||
@@ -87,7 +87,7 @@ pub use strategy_runner::{
|
||||
};
|
||||
|
||||
// Import Side directly (no alias needed)
|
||||
use common::types::basic::Side;
|
||||
use common::basic::Side;
|
||||
|
||||
/// Main backtesting engine configuration
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
|
||||
@@ -15,7 +15,7 @@ use statrs::statistics::{Statistics, VarianceN};
|
||||
use tokio::sync::RwLock;
|
||||
use tracing::{debug, info, warn};
|
||||
|
||||
use common::types::*;
|
||||
use common::*;
|
||||
|
||||
use crate::strategy_tester::{PerformanceSnapshot, TradeRecord};
|
||||
|
||||
|
||||
@@ -12,8 +12,8 @@ use std::{
|
||||
|
||||
use anyhow::{Context, Result};
|
||||
use chrono::{DateTime, Utc};
|
||||
use common::types::Timestamp;
|
||||
use common::types::{Symbol, Decimal, Quantity, MarketEvent, Price};
|
||||
use common::Timestamp;
|
||||
use common::{Symbol, Decimal, Quantity, MarketEvent, Price};
|
||||
use crossbeam_channel::{bounded, Receiver, Sender};
|
||||
use dashmap::DashMap;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
|
||||
use anyhow::Result;
|
||||
use async_trait::async_trait;
|
||||
use common::types::basic::Side;
|
||||
use common::types::*;
|
||||
use common::basic::Side;
|
||||
use common::*;
|
||||
// Use canonical types from ML module
|
||||
use ml::{Features, ModelPrediction};
|
||||
|
||||
|
||||
@@ -19,13 +19,13 @@ use dashmap::DashMap;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use tokio::sync::{mpsc, RwLock};
|
||||
use tracing::{debug, error, info, warn};
|
||||
use common::types::basic::{
|
||||
use common::{
|
||||
Order, OrderId, Position, Price, Quantity, Side as OrderSide, Symbol,
|
||||
TimeInForce,
|
||||
};
|
||||
use common::types::{OrderStatus, OrderType};
|
||||
use common::types::events::MarketEvent;
|
||||
use common::types::*;
|
||||
use common::{OrderStatus, OrderType};
|
||||
use trading_engine::types::events::MarketEvent;
|
||||
use common::*;
|
||||
use uuid::Uuid;
|
||||
// TECHNICAL DEBT ELIMINATED - Use String and DateTime<Utc> directly
|
||||
use crate::replay_engine::{MarketReplay, ReplayEvent};
|
||||
|
||||
@@ -4,7 +4,7 @@ use backtesting::{
|
||||
create_adaptive_strategy_with_config, AdaptiveStrategyConfig, AdaptiveStrategyRunner,
|
||||
BacktestConfig, BacktestEngine, FeatureSettings, RiskSettings, Strategy,
|
||||
};
|
||||
use common::types::*;
|
||||
use common::*;
|
||||
|
||||
#[tokio::test]
|
||||
async fn test_dqn_strategy_integration() {
|
||||
|
||||
Reference in New Issue
Block a user