diff --git a/asv_bench/benchmarks/package.py b/asv_bench/benchmarks/package.py index 34fe4929a752b..257c82cba8878 100644 --- a/asv_bench/benchmarks/package.py +++ b/asv_bench/benchmarks/package.py @@ -11,7 +11,7 @@ def time_import(self): # measurement of the import time we actually care about, # without the subprocess or interpreter overhead cmd = [sys.executable, "-X", "importtime", "-c", "import pandas as pd"] - p = subprocess.run(cmd, stderr=subprocess.PIPE) + p = subprocess.run(cmd, stderr=subprocess.PIPE, check=True) line = p.stderr.splitlines()[-1] field = line.split(b"|")[-2].strip() diff --git a/pyproject.toml b/pyproject.toml index 2c032fd4d8dea..70bed7d9aeff9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -146,7 +146,6 @@ disable = [ "self-assigning-variable", "self-cls-assignment", "signature-differs", - "subprocess-run-check", "super-init-not-called", "try-except-raise", "undefined-loop-variable", diff --git a/scripts/run_autotyping.py b/scripts/run_autotyping.py index f537b8d16c77a..032f742200a07 100644 --- a/scripts/run_autotyping.py +++ b/scripts/run_autotyping.py @@ -28,6 +28,7 @@ def main(argv: Sequence[str] | None = None) -> None: *args.paths, "--aggressive", ], + check=True, ) sys.exit(output.returncode) diff --git a/scripts/validate_docstrings.py b/scripts/validate_docstrings.py index cbf02bc0a0156..a86630eba7d5d 100755 --- a/scripts/validate_docstrings.py +++ b/scripts/validate_docstrings.py @@ -211,7 +211,7 @@ def validate_pep8(self): file.write(content) file.flush() cmd = ["python", "-m", "flake8", "--quiet", "--statistics", file.name] - response = subprocess.run(cmd, capture_output=True, text=True) + response = subprocess.run(cmd, capture_output=True, check=False, text=True) stdout = response.stdout stdout = stdout.replace(file.name, "") messages = stdout.strip("\n")