Skip to content

Commit 9550d3b

Browse files
committed
reduce config34 cache, add no_cache config34 in node stats
1 parent 871c095 commit 9550d3b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

mytoncore/functions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ def get_ok_error(value: str):
317317

318318
# statistics['node'] = [stats_from_election_id, stats_from_prev_min, stats_now]
319319

320-
election_id = ton.GetConfig34()['startWorkTime']
320+
election_id = ton.GetConfig34(no_cache=True)['startWorkTime']
321321
if 'node' not in statistics or len(statistics['node']) == 0:
322322
statistics['node'] = [None, data]
323323
elif len(statistics['node']) < 3:

mytoncore/mytoncore.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -930,11 +930,11 @@ def GetConfig32(self):
930930
return config32
931931
#end define
932932

933-
def GetConfig34(self):
933+
def GetConfig34(self, no_cache: bool = False):
934934
# Get buffer
935935
bname = "config34"
936-
buff = self.GetFunctionBuffer(bname, timeout=60)
937-
if buff:
936+
buff = self.GetFunctionBuffer(bname, timeout=10)
937+
if buff and not no_cache:
938938
return buff
939939
#end if
940940

0 commit comments

Comments
 (0)