aboutsummaryrefslogtreecommitdiff
path: root/market.py
diff options
context:
space:
mode:
Diffstat (limited to 'market.py')
-rw-r--r--market.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/market.py b/market.py
index e16641c..7a37cf6 100644
--- a/market.py
+++ b/market.py
@@ -5,6 +5,7 @@ import psycopg2
5from store import * 5from store import *
6from cachetools.func import ttl_cache 6from cachetools.func import ttl_cache
7from datetime import datetime 7from datetime import datetime
8import datetime
8from retry import retry 9from retry import retry
9import portfolio 10import portfolio
10 11
@@ -28,7 +29,7 @@ class Market:
28 for key in ["user_id", "market_id", "pg_config"]: 29 for key in ["user_id", "market_id", "pg_config"]:
29 setattr(self, key, kwargs.get(key, None)) 30 setattr(self, key, kwargs.get(key, None))
30 31
31 self.report.log_market(self.args, self.user_id, self.market_id) 32 self.report.log_market(self.args)
32 33
33 @classmethod 34 @classmethod
34 def from_config(cls, config, args, **kwargs): 35 def from_config(cls, config, args, **kwargs):
@@ -40,7 +41,7 @@ class Market:
40 41
41 def store_report(self): 42 def store_report(self):
42 self.report.merge(Portfolio.report) 43 self.report.merge(Portfolio.report)
43 date = datetime.now() 44 date = datetime.datetime.now()
44 if self.args.report_path is not None: 45 if self.args.report_path is not None:
45 self.store_file_report(date) 46 self.store_file_report(date)
46 if self.pg_config is not None and self.args.report_db: 47 if self.pg_config is not None and self.args.report_db: