aboutsummaryrefslogtreecommitdiffstats
path: root/python/master.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/master.py')
-rw-r--r--python/master.py23
1 files changed, 0 insertions, 23 deletions
diff --git a/python/master.py b/python/master.py
deleted file mode 100644
index 3db5a6d7..00000000
--- a/python/master.py
+++ /dev/null
@@ -1,23 +0,0 @@
-import redis
-from pickle import dumps
-import datetime
-import os
-import time
-from common import root
-
-def run():
- dealsfile = os.path.join(root, "scripts", "deals_to_price.txt")
- q = redis.Redis(unix_socket_path='/var/run/redis/redis.sock')
-
- while True:
- workdate = str(datetime.date.today())
- if os.path.exists(dealsfile):
- with open(dealsfile) as fh:
- for line in fh:
- dealname, reinvflag = line.rstrip().split("\t")
- q.rpush("tasks", dumps(("build_portfolio", [workdate, dealname, reinvflag]), protocol=2))
- os.unlink(dealsfile)
- time.sleep(3)
-
-if __name__=="__main__":
- run()