Commit 1174318f authored by wenwen.tang's avatar wenwen.tang 😕

bugfix

parent e71c080d
...@@ -21,7 +21,7 @@ logger = logging.getLogger(__name__) ...@@ -21,7 +21,7 @@ logger = logging.getLogger(__name__)
@component(bean_name='backtest') @component(bean_name='backtest')
class BacktestExecutor(RoboExecutor): class BacktestExecutor(RoboExecutor):
@autowired(names={'syncs': 'navs-sync'}) @autowired
def __init__(self, datum: Datum = None, pool: AssetPool = None, def __init__(self, datum: Datum = None, pool: AssetPool = None,
syncs: List[DataSync] = None, export: RoboExportor = None, syncs: List[DataSync] = None, export: RoboExportor = None,
builder: PortfoliosBuilder = None, hold: PortfoliosHolder = None, builder: PortfoliosBuilder = None, hold: PortfoliosHolder = None,
...@@ -30,7 +30,7 @@ class BacktestExecutor(RoboExecutor): ...@@ -30,7 +30,7 @@ class BacktestExecutor(RoboExecutor):
self._pool = pool self._pool = pool
self._builder = builder self._builder = builder
self._hold = hold self._hold = hold
self._syncs = [syncs] self._syncs = syncs
self._export = export self._export = export
self._signal = signal self._signal = signal
self._config = get_config(__name__)['backtest'] self._config = get_config(__name__)['backtest']
...@@ -135,17 +135,14 @@ class BacktestExecutor(RoboExecutor): ...@@ -135,17 +135,14 @@ class BacktestExecutor(RoboExecutor):
@component(bean_name='real') @component(bean_name='real')
class RealExecutor(RoboExecutor): class RealExecutor(RoboExecutor):
@autowired(names={'daily_export': 'daily-real-export', 'monitor_export': 'daily-monitor-export', @autowired(names={'daily_export': 'daily-real-export', 'monitor_export': 'daily-monitor-export'})
# todo 上线用tw api
# 'syncs': 'tw-navs-sync'})
'syncs': 'navs-sync'})
def __init__(self, builder: PortfoliosBuilder = None, hold: PortfoliosHolder = None, syncs: List[DataSync] = None, def __init__(self, builder: PortfoliosBuilder = None, hold: PortfoliosHolder = None, syncs: List[DataSync] = None,
daily_export: RoboExportor = None, monitor_export: RoboExportor = None, pool: AssetPool = None, daily_export: RoboExportor = None, monitor_export: RoboExportor = None, pool: AssetPool = None,
signal: RebalanceSignal = None): signal: RebalanceSignal = None):
self._builder = builder self._builder = builder
self._pool = pool self._pool = pool
self._hold = hold self._hold = hold
self._syncs = [syncs] self._syncs = syncs
self._daily_export = daily_export self._daily_export = daily_export
self._monitor_export = monitor_export self._monitor_export = monitor_export
self._config = get_config(__name__)['real'] self._config = get_config(__name__)['real']
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment