Skip to content

Commit fbdfc5a

Browse files
cpcloudcursoragent
andcommitted
fix(pathfinder): satisfy pre-commit for spawned runner utilities
Add the missing type annotations required by mypy and keep the test shim exporting only the runner entry point so lint checks pass cleanly. Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent a4ea4b7 commit fbdfc5a

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

cuda_pathfinder/cuda/pathfinder/_utils/spawned_process_runner.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,19 @@ class CompletedProcess:
2424

2525

2626
class ChildProcessWrapper:
27-
def __init__(self, result_queue, target, args, kwargs):
27+
def __init__(
28+
self,
29+
result_queue: Any,
30+
target: Callable[..., None],
31+
args: Sequence[Any] | None,
32+
kwargs: dict[str, Any] | None,
33+
) -> None:
2834
self.target = target
2935
self.args = () if args is None else args
3036
self.kwargs = {} if kwargs is None else kwargs
3137
self.result_queue = result_queue
3238

33-
def __call__(self):
39+
def __call__(self) -> None:
3440
# Capture stdout/stderr
3541
old_stdout = sys.stdout
3642
old_stderr = sys.stderr
Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
# SPDX-FileCopyrightText: Copyright (c) 2025-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
22
# SPDX-License-Identifier: Apache-2.0
33

4-
from cuda.pathfinder._utils.spawned_process_runner import (
5-
PROCESS_KILLED,
6-
PROCESS_NO_RESULT,
7-
CompletedProcess,
8-
run_in_spawned_child_process,
9-
)
4+
from cuda.pathfinder._utils.spawned_process_runner import run_in_spawned_child_process
5+
6+
__all__ = ["run_in_spawned_child_process"]

0 commit comments

Comments
 (0)