uv/.github/workflows
John Mumm 2df06ebfbc Require `uv venv --clear` before removing an existing directory (#14309)
By default, `uv venv <venv-name>` currently removes the `<venv-name`>
directory if it exists. This can be surprising behavior: not everyone
expects an existing environment to be overwritten. This PR updates the
default to fail if a non-empty `<venv-name>` directory already exists
and neither `--allow-existing` nor the new `-c/--clear` option is
provided (if a TTY is detected, it prompts first). If it's not a TTY,
then uv will only warn and not fail for now — we'll make this an error
in the future. I've also added a corresponding `UV_VENV_CLEAR` env var.

I've chosen to use `--clear` instead of `--force` for this option
because it is used by the `venv` module and `virtualenv` and will be
familiar to users. I also think its meaning is clearer in this context
than `--force` (which could plausibly mean force overwrite just the
virtual environment files, which is what our current `--allow-existing`
option does).

Closes #1472.

---------

Co-authored-by: Zanie Blue <contact@zanie.dev>
2025-07-17 17:20:21 -05:00
..
build-binaries.yml Update PyO3/maturin-action action to v1.49.3 (#14363) 2025-06-30 19:16:53 -04:00
build-docker.yml feat(docker): set default `UV_TOOL_BIN_DIR` on docker images (#13391) 2025-07-17 17:20:21 -05:00
ci.yml Require `uv venv --clear` before removing an existing directory (#14309) 2025-07-17 17:20:21 -05:00
publish-docs.yml Update actions/setup-python action to v5.6.0 (#13150) 2025-04-27 21:38:50 -04:00
publish-pypi.yml Update astral-sh/setup-uv action to v6.3.1 (#14360) 2025-06-29 22:17:48 -04:00
release.yml Update cargo-dist (#14156) 2025-06-20 14:20:01 -04:00
setup-dev-drive.ps1 move the test buckets dir into the canonicalized temp dir 2025-06-26 14:56:20 -07:00
sync-python-releases.yml Update astral-sh/setup-uv action to v6.3.1 (#14360) 2025-06-29 22:17:48 -04:00