For failed steps, yield fake 0 instead of artificial wait.

Because the caller can impose their own wait between steps
of the generator.
master
Ethan Dalool 2019-06-25 15:00:38 -07:00
parent feed4c5621
commit bca5addab3
1 changed files with 3 additions and 2 deletions

View File

@ -154,8 +154,9 @@ def _livestream_as_a_generator(
yield newitems
except Exception:
traceback.print_exc()
print('Retrying in 5...')
time.sleep(5)
print('Retrying...')
step = {'tsdb': database, 'new_comments': 0, 'new_submissions': 0}
yield step
def _livestream_helper(
submission_function=None,