From e5b2adda6bc82b642fbf1ce3f393cb581acc63e7 Mon Sep 17 00:00:00 2001 From: tntexplosivesltd Date: Wed, 22 Nov 2023 23:23:30 +1300 Subject: [PATCH] Fix linting --- .github/workflows/format.yml | 2 +- tools/checkorder/checkorder.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml index ad54d7cf..134fe6b8 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/format.yml @@ -18,7 +18,7 @@ jobs: shell: bash run: | pip install -r tools/reccmp/requirements.txt - pylint tools + pylint tools --ignore=build,tests black --check tools - name: Run clang-format diff --git a/tools/checkorder/checkorder.py b/tools/checkorder/checkorder.py index 2398ad30..0ca1d102 100644 --- a/tools/checkorder/checkorder.py +++ b/tools/checkorder/checkorder.py @@ -16,7 +16,7 @@ def check_file(filename: str, verbose: bool = False) -> bool: """Open and read the given file, then check whether the code blocks are in order. If verbose, print each block.""" - with open(filename, "r") as f: + with open(filename, "r", encoding="utf-8") as f: code_blocks = find_code_blocks(f) bad_comments = [