diff options
author | Jon Atack <jon@atack.com> | 2022-05-25 23:45:28 +0200 |
---|---|---|
committer | Jon Atack <jon@atack.com> | 2022-05-26 14:59:29 +0200 |
commit | 75848ec2daa43b648cf497c59924d389e8243320 (patch) | |
tree | a90306e98ec5c6a1ded5d46df27748ebccd00323 | |
parent | b4f686952a60bbadc7ed2250651d0d6af0959f4d (diff) |
scripts and tools: update lint-logs.py to detect LogPrintLevel()
and add WalletLogPrintf() (already detected) to the lint-logs.py suggestion
Co-authored-by: laanwj <126646+laanwj@users.noreply.github.com>
-rwxr-xr-x | test/lint/lint-logs.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/lint/lint-logs.py b/test/lint/lint-logs.py index e6c4c068fb..de53729b4e 100755 --- a/test/lint/lint-logs.py +++ b/test/lint/lint-logs.py @@ -16,12 +16,12 @@ from subprocess import check_output def main(): - logs_list = check_output(["git", "grep", "--extended-regexp", r"LogPrintf?\(", "--", "*.cpp"], universal_newlines=True, encoding="utf8").splitlines() + logs_list = check_output(["git", "grep", "--extended-regexp", r"(LogPrintLevel|LogPrintf?)\(", "--", "*.cpp"], universal_newlines=True, encoding="utf8").splitlines() unterminated_logs = [line for line in logs_list if not re.search(r'(\\n"|/\* Continued \*/)', line)] if unterminated_logs != []: - print("All calls to LogPrintf() and LogPrint() should be terminated with \\n") + print("All calls to LogPrintf(), LogPrint(), LogPrintLevel(), and WalletLogPrintf() should be terminated with \"\\n\".") print("") for line in unterminated_logs: |