fix(python): apply uv_venv_create_args in auto-venv code path#7310
Merged
Conversation
The uv_venv_create_args setting was ignored when using settings.python.uv_venv_auto, though it worked correctly with env._.python.venv. This adds the missing settings lookup to the auto-venv code path. Fixes #7252 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes a bug where the uv_venv_create_args setting was being ignored when using the uv_venv_auto feature. The fix ensures that custom venv creation arguments are consistently applied in both the auto-venv code path and the manual env._.python.venv config directive path.
Key Changes:
- Added
uv_venv_create_argsapplication in the auto-venv creation code path
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Hyperfine Performance
|
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.12.7 x -- echo |
22.8 ± 1.1 | 21.1 | 28.2 | 1.00 |
mise x -- echo |
23.4 ± 1.1 | 21.4 | 28.7 | 1.02 ± 0.07 |
mise env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.12.7 env |
22.2 ± 1.1 | 20.1 | 27.1 | 1.00 |
mise env |
22.8 ± 1.1 | 20.6 | 27.6 | 1.03 ± 0.07 |
mise hook-env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.12.7 hook-env |
22.1 ± 0.9 | 20.4 | 26.9 | 1.00 |
mise hook-env |
22.9 ± 1.3 | 20.7 | 32.9 | 1.04 ± 0.07 |
mise ls
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.12.7 ls |
18.5 ± 1.0 | 16.8 | 24.9 | 1.00 |
mise ls |
18.9 ± 1.8 | 16.7 | 32.2 | 1.02 ± 0.11 |
xtasks/test/perf
| Command | mise-2025.12.7 | mise | Variance |
|---|---|---|---|
| install (cached) | 114ms | 114ms | +0% |
| ls (cached) | 72ms | 70ms | +2% |
| bin-paths (cached) | 80ms | 77ms | +3% |
| task-ls (cached) | 479ms | 463ms | +3% |
jdx
pushed a commit
that referenced
this pull request
Dec 15, 2025
### 🚀 Features - **(conda)** add dependency resolution for conda packages by @jdx in [#7280](#7280) - **(go)** add created_at support to ls-remote --json by @jdx in [#7305](#7305) - **(hook-env)** add hook_env.cache_ttl and hook_env.chpwd_only settings for NFS optimization by @jdx in [#7312](#7312) - **(hooks)** add MISE_TOOL_NAME and MISE_TOOL_VERSION to preinstall/postinstall hooks by @jdx in [#7311](#7311) - **(shell_alias)** add shell_alias support for cross-shell aliases by @jdx in [#7316](#7316) - **(tool)** add security field to mise tool --json by @jdx in [#7303](#7303) - add --before flag for date-based version filtering by @jdx in [#7298](#7298) ### 🐛 Bug Fixes - **(aqua)** support cosign v3 bundle verification by @jdx in [#7314](#7314) - **(config)** use correct config_root in tera context for hooks by @jdx in [#7309](#7309) - **(nu)** fix nushell deactivation script on Windows by @fu050409 in [#7213](#7213) - **(python)** apply uv_venv_create_args in auto-venv code path by @jdx in [#7310](#7310) - **(shell)** escape exe path in activation scripts for paths with spaces by @jdx in [#7315](#7315) - **(task)** parallelize exec_env loading to fix parallel task execution by @jdx in [#7313](#7313) - track downloads for python and java by @jdx in [#7304](#7304) - include full tool ID in download track by @jdx in [#7320](#7320) ### 📚 Documentation - Switch `postinstall` code to be shell-agnostic by @thejcannon in [#7317](#7317) ### 🧪 Testing - **(e2e)** disable debug mode by default for windows-e2e by @jdx in [#7318](#7318) ### New Contributors - @fu050409 made their first contribution in [#7213](#7213)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
uv_venv_create_argsbeing ignored when usingsettings.python.uv_venv_autoenv._.python.venvconfig directiveTest plan
uv.lockuv_venv_auto = trueanduv_venv_create_args = ['--seed']in settings.venvdirectorymiseto trigger auto-venv creation--seed(pip/setuptools installed)Fixes #7252
🤖 Generated with Claude Code
Note
Pass configured uv_venv_create_args to the uv venv command during auto-venv creation.
Settings.python.uv_venv_create_argsto theuv venvcommand when auto-creating the venv insrc/uv.rs.Written by Cursor Bugbot for commit a3b881b. This will update automatically on new commits. Configure here.