diff --git a/scripts/regen-words.py b/scripts/regen-words.py index 54c9ed149..0b728a8b6 100755 --- a/scripts/regen-words.py +++ b/scripts/regen-words.py @@ -3,12 +3,12 @@ import sys import json -from app import config -from app.log import LOG - rootDir = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) sys.path.append(rootDir) +from app import config # noqa: E402 +from app.log import LOG # noqa: E402 + LOG.i(f"Reading {config.WORDS_FILE_PATH} file") words = [ word.strip() @@ -23,11 +23,13 @@ with open(destFile, "wb") as fd: fd.write( f"""# -#This file is auto-generated. Please run {sys.argv[0]} to re-generate it +# This file is auto-generated. Please run {sys.argv[0]} to re-generate it # import json -safe_words = json.loads('{serialized_words}') +safe_words = json.loads( + '{serialized_words}' +) """.encode("utf-8") )