Skip to content

[Windows] Processes spawned by uv are not killed when uv is killed #11817

@gau-nernst

Description

@gau-nernst

Summary

# sleep.py
import time

time.sleep(100000)
uv run sleep.py

Then I manually kill uv process in Task manager. I can still see the Python process.

On MacOS/Linux, if I kill it with kill pid (which sends SIGTERM), the Python process will exit. Though I also notice that if I kill with SIGKILL instead kill -9 pid, the Python process does not stop.

In a larger context, in my application, I'm trying to spawn uv as a subprocess to launch Python apps. And I want to be able to kill the uv subprocess and its python process. Having troubles to do it on Windows right now.

Platform

Windows 11 64bit

Version

uv 0.6.2 (6d3614e 2025-02-19)

Python version

No response

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions