Skip to content

Commit 37f4039

Browse files
committed
Handle multiprocessing start methods besides fork
Since Python 3.14 'forkserver' is now the default multiprocessing start method instead of 'fork', and with this spawn method we need to pass the `multiprocessing.Event` that we're sharing between the pytest process and the monitoring process along explicitly, rather than counting on a `fork()` to share the same object between the two processes.
1 parent ed32d75 commit 37f4039

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/pytest_pystack/_monitor_process.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ def start(config):
2020
config,
2121
os.getpid(),
2222
_queue,
23+
debug_detected,
2324
),
2425
name="pystack_monitor",
2526
)
@@ -35,7 +36,7 @@ def stop():
3536
_process.kill()
3637

3738

38-
def _run_monitor(config: PystackConfig, pid, queue):
39+
def _run_monitor(config: PystackConfig, pid, queue, debug_detected):
3940
pystack_cmd = [
4041
config.pystack_path,
4142
"remote",

0 commit comments

Comments
 (0)