mirror of
https://github.com/wassname/catalyst.git
synced 2026-07-24 13:00:57 +08:00
ENH: Replace update_asset_finder with write_data
The write_data methods invokes the relevant AssetDBWriter subclass to write data to the database. update_asset_finder is no longer a relevant method since the AssetFinder is strictly a reader class.
This commit is contained in:
@@ -205,11 +205,11 @@ class TradingAlgorithm(object):
|
||||
# Update the TradingEnvironment with the provided asset metadata
|
||||
self.trading_environment = kwargs.pop('env',
|
||||
TradingEnvironment.instance())
|
||||
self.trading_environment.update_asset_finder(
|
||||
asset_finder=kwargs.pop('asset_finder', None),
|
||||
asset_metadata=kwargs.pop('asset_metadata', None),
|
||||
identifiers=kwargs.pop('identifiers', None)
|
||||
self.trading_environment.write_data(
|
||||
equities_data=kwargs.pop('asset_metadata', None),
|
||||
equities_identifiers=kwargs.pop('identifiers', None),
|
||||
)
|
||||
|
||||
# Pull in the environment's new AssetFinder for quick reference
|
||||
self.asset_finder = self.trading_environment.asset_finder
|
||||
self.init_engine(kwargs.pop('ffc_loader', None))
|
||||
|
||||
Reference in New Issue
Block a user