Skip to content

Commit

Permalink
Fix log count handling.
Browse files Browse the repository at this point in the history
  • Loading branch information
weisi committed May 26, 2020
1 parent 4916116 commit b7a8bd5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ def is_good_title(title, previous_title=None):


def log_count(count):
if count % _LOG_EVERY == 0:
logging.info(f'{count} words generated')
logging.info(f'{count} words generated')


def make_output(word, pinyin):
Expand All @@ -69,7 +68,8 @@ def main():
continue
print(make_output(title, pinyin))
result_count += 1
log_count(result_count)
if result_count % _LOG_EVERY == 0:
log_count(result_count)
previous_title = title
log_count(result_count)

Expand Down

0 comments on commit b7a8bd5

Please sign in to comment.