Make config.py items configurable via ENV and set sane default values

This commit is contained in:
Jack Zampolin
2018-01-17 15:38:06 -08:00
parent 4004761b79
commit bd1e041363
6 changed files with 83 additions and 59 deletions

View File

@@ -9,8 +9,6 @@
import json
from config import BLOCKSTACKD_IP
from config import BLOCKSTACKD_PORT
from config import NAMES_FILE, NEW_NAMES_FILE
# hack to ensure local, until we update client
from blockstack_client import client as bs_client
@@ -33,27 +31,8 @@ if __name__ == "__main__":
print old_counter
#while 1:
# # start session using blockstack_client
# #bs_client.session(server_host=BLOCKSTACKD_IP, server_port=BLOCKSTACKD_PORT,
# # set_global=True)
total_names = bs_client.get_all_names()
# if len(new_names) == 0:
# break
# # check for blockstack errors
# if len(new_names) == 1 and "error" in new_names:
# print "Blockstack error: " + new_names["error"]
# break
# total_names += new_names
# offset += count
# print offset
new_counter = len(total_names)
if new_counter > old_counter: