Skip to content

Commit ac35af3

Browse files
pre-commit fixes
1 parent bc779ff commit ac35af3

1 file changed

Lines changed: 4 additions & 12 deletions

File tree

codeflash/benchmarking/trace_benchmarks.py

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def trace_benchmarks_pytest(
1919
benchmark_env["PYTHONPATH"] = str(project_root)
2020
else:
2121
benchmark_env["PYTHONPATH"] += os.pathsep + str(project_root)
22-
22+
2323
is_windows = sys.platform == "win32"
2424
cmd_list = [
2525
SAFE_SYS_EXECUTABLE,
@@ -28,7 +28,7 @@ def trace_benchmarks_pytest(
2828
tests_root,
2929
trace_file,
3030
]
31-
31+
3232
if is_windows:
3333
# Use Windows-safe subprocess handling to avoid file locking issues
3434
creationflags = subprocess.CREATE_NEW_PROCESS_GROUP
@@ -49,19 +49,11 @@ def trace_benchmarks_pytest(
4949
with contextlib.suppress(OSError):
5050
process.kill()
5151
stdout_content, stderr_content = process.communicate(timeout=5)
52-
raise subprocess.TimeoutExpired(
53-
cmd_list, timeout, output=stdout_content, stderr=stderr_content
54-
) from None
52+
raise subprocess.TimeoutExpired(cmd_list, timeout, output=stdout_content, stderr=stderr_content) from None
5553
result = subprocess.CompletedProcess(cmd_list, returncode, stdout_content, stderr_content)
5654
else:
5755
result = subprocess.run(
58-
cmd_list,
59-
cwd=project_root,
60-
check=False,
61-
capture_output=True,
62-
text=True,
63-
env=benchmark_env,
64-
timeout=timeout,
56+
cmd_list, cwd=project_root, check=False, capture_output=True, text=True, env=benchmark_env, timeout=timeout
6557
)
6658
if result.returncode != 0:
6759
if "ERROR collecting" in result.stdout:

0 commit comments

Comments
 (0)