WIP handle input parse
This commit is contained in:
parent
84e89dbfae
commit
025e728686
@ -12,9 +12,14 @@ class RunStore:
|
|||||||
self.procstore = os.path.join(basedir, 'eth_stat_syncerd')
|
self.procstore = os.path.join(basedir, 'eth_stat_syncerd')
|
||||||
|
|
||||||
|
|
||||||
|
def get_postfix_path(self, name, postfix):
|
||||||
|
file_path = os.path.join(self.procstore, postfix, name)
|
||||||
|
return file_path
|
||||||
|
|
||||||
|
|
||||||
def put(self, o, postfix):
|
def put(self, o, postfix):
|
||||||
for k in o:
|
for k in o:
|
||||||
file_path = os.path.join(self.procstore, postfix, k)
|
file_path = self.get_postfix_path(k, postfix)
|
||||||
d = os.path.dirname(file_path)
|
d = os.path.dirname(file_path)
|
||||||
try:
|
try:
|
||||||
os.stat(d)
|
os.stat(d)
|
||||||
@ -25,6 +30,14 @@ class RunStore:
|
|||||||
f.close()
|
f.close()
|
||||||
|
|
||||||
|
|
||||||
|
def get(self, name, postfix):
|
||||||
|
file_path = self.get_postfix_path(name, postfix)
|
||||||
|
f = open(file_path, 'r')
|
||||||
|
r = f.read()
|
||||||
|
f.close()
|
||||||
|
return r
|
||||||
|
|
||||||
|
|
||||||
class GasAggregator:
|
class GasAggregator:
|
||||||
|
|
||||||
def __init__(self, store, capacity):
|
def __init__(self, store, capacity):
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
chainsyncer==0.0.1a22
|
chainsyncer~=0.0.1a22
|
||||||
chainlib==0.0.2a6
|
chainlib~=0.0.2a6
|
||||||
|
jsonrpc_std~=0.0.1a1
|
||||||
|
Loading…
Reference in New Issue
Block a user