Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initialize colorama only once #27006

Merged
merged 1 commit into from Jun 20, 2020
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

Initialize colorama only once

  • Loading branch information
saschanaz committed Jun 20, 2020
commit 97bfab73b435930f6f2a8aeb3044b513da516917
@@ -1140,13 +1140,12 @@ def scan(only_changed_files=False, progress=True, stylo=False, no_wpt=False):
file_errors, dep_license_errors)

error = None
colorama.init()
for error in errors:
colorama.init()
print("\r\033[94m{}\033[0m:\033[93m{}\033[0m: \033[91m{}\033[0m".format(*error))

print()
if error is None:
colorama.init()
print("\033[92mtidy reported no errors.\033[0m")

return int(error is not None)
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.