mirror of
https://github.com/norohind/jubilant-system-core.git
synced 2025-04-14 02:27:13 +03:00
Add retries_list.txt system
This commit is contained in:
parent
fea8380529
commit
fdae3b970e
@ -22,7 +22,7 @@ def check_int(func: callable) -> callable:
|
||||
def _last_records(operation_id: int, limit: int) -> list[dict]:
|
||||
last_exception: Exception | None = None
|
||||
|
||||
for retry in range(0, 3):
|
||||
for retry in range(0, 10):
|
||||
try:
|
||||
return Hook.get_db().execute(
|
||||
HookUtils.SQL_REQUESTS.GET_HISTORICAL_INFO,
|
||||
@ -41,6 +41,9 @@ def _last_records(operation_id: int, limit: int) -> list[dict]:
|
||||
last_exception = e
|
||||
continue
|
||||
|
||||
with open('retries_list.txt', mode='a') as retries_file:
|
||||
retries_file.write(f'{operation_id}\n')
|
||||
|
||||
raise last_exception
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user