First pass of ruff check fixes (#26257)

This commit is contained in:
Joel Challis
2026-07-18 04:06:19 +01:00
committed by GitHub
parent bea6a83a12
commit cf01e22447
18 changed files with 56 additions and 75 deletions
+3 -1
View File
@@ -1,3 +1,5 @@
from typing import Sequence
import platform
from subprocess import DEVNULL
@@ -21,7 +23,7 @@ def check_subcommand_stdin(file_to_read, command, *args):
return result
def check_returncode(result, expected=[0]):
def check_returncode(result, expected: Sequence[int] = [0]):
"""Print stdout if `result.returncode` does not match `expected`.
"""
if result.returncode not in expected: