Skip to content

Commit

Permalink
[REMOVE]
Browse files Browse the repository at this point in the history
  • Loading branch information
woutdenolf committed Aug 12, 2024
1 parent 5eb0a16 commit 1f17319
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/silx/utils/retry.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,10 @@ def _retry_loop(retry_timeout=None, retry_period=None, retry_on_error=None):
else:
t0 = None
retry_state = {"t0": t0, "exception": None, "retry_on_error": retry_on_error}
print("AAA start timer", retry_state["t0"])
while True:
yield retry_state
print("BBB check timer", time.time(), time.time() - retry_state["t0"])
if has_timeout and (time.time() - retry_state["t0"]) > retry_timeout:
err_msg = "%s seconds" % retry_timeout
cause = retry_state.get("exception")
Expand Down Expand Up @@ -145,6 +147,7 @@ def wrapper(*args, **kw):
# restart the retry loop
if retry_state["t0"] is not None:
retry_state["t0"] = time.time()
print("AAA reset timer", retry_state["t0"])
retry_state["retry_on_error"] = oretry_on_error
return

Expand Down

0 comments on commit 1f17319

Please sign in to comment.