Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request addresses two key areas related to Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces documentation clarifications and bug fixes for python.uv_venv_auto. The documentation is updated to clarify the deprecation of the true value. A bug causing infinite recursion when a mise shim for uv is in the PATH is fixed by adding a which_no_shims function to exclude the shim directory during executable lookups. A new e2e test verifies this fix. Additionally, the return value from the venv creation function is now handled correctly to prevent errors with non-existent venvs. The changes are well-implemented and I have no issues to report.
4f0e548 to
d71e0b2
Compare
There was a problem hiding this comment.
Pull request overview
Improves python.uv_venv_auto behavior and documentation by clarifying legacy vs recommended configuration, and preventing infinite recursion when a uv shim is present on PATH during venv auto-creation.
Changes:
- Fix
uv_venv()to correctly handlecreate_python_venv()returningOk(false)(skip loading a non-existent venv). - Add
which_no_shims()and use it for internaluvlookup to avoid invoking mise shims (and recursive re-entry). - Update E2E coverage for shim-exclusion behavior and clarify Python docs around the legacy
truesetting value.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/uv.rs | Handle Ok(false) from venv creation to avoid loading a missing .venv. |
| src/file.rs | Introduce which_no_shims() to avoid shim-based recursion in internal tool lookups. |
| src/config/env_directive/venv.rs | Use which_no_shims("uv") when creating venvs. |
| e2e/core/test_python_uv_venv | Add regression test for shim recursion avoidance; switch config filename to mise.toml. |
| docs/lang/python.md | Clarify that only the true value is legacy, and document a stricter UV_PYTHON configuration pattern. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Greptile SummaryThis PR fixes a critical bug that caused infinite subprocess recursion when mise shims were on PATH during venv creation, and clarifies misleading documentation about the Key Changes:
Confidence Score: 5/5
Important Files Changed
Last reviewed commit: d71e0b2 |
|
bugbot run verbose=true |
|
Bugbot request id: serverGenReqId_ce9f1153-3037-44dc-82c3-62279e95492e |
Head branch was pushed to by a user without write access
The true value is considered legacy and will be deprecated in a future release (2026.7), but the setting itself is not going away. Clarify the difference between legacy `true` (exports UV_PYTHON with just the version number) and the new recommended approach (using `tools.python.path` to strictly pin uv to mise-managed Python). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
b14c3c0 to
176ad55
Compare
|
@jdx, I pushed changes to address the Copilot comments which I think were valid. |
…_auto
When `uv_venv_auto = "create|source"` is set and a mise shim for uv
exists on PATH (from another project), `which_non_pristine("uv")` would
find the shim. Running the shim invokes `mise exec`, which re-enters
the same venv creation path, causing infinite subprocess recursion
(printing "mise creating venv with uv at: ..." endlessly).
Fix by adding `which_no_shims()` that excludes the mise shim directory
from PATH searches, and using it in `create_python_venv`. Also handle
the `Ok(false)` return case in `uv_venv()` so that when venv creation
is skipped (e.g. uv unavailable), we correctly return None instead of
falling through to `load_venv` on a non-existent path.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
176ad55 to
c6442fd
Compare
### 🚀 Features - **(hooks)** add task references to hooks and watch_files by @jdx in [#8400](#8400) - **(prepare)** add git-submodule built-in provider by @jdx in [#8407](#8407) - **(prepare)** add human-readable stale reasons to prepare output by @jdx in [#8408](#8408) - **(prepare)** add dependency ordering to prepare steps by @jdx in [#8401](#8401) - **(prepare)** add --explain flag for provider diagnostics by @jdx in [#8409](#8409) - **(prepare)** add per-provider timeout support by @jdx in [#8405](#8405) - **(prepare)** add blake3 content-hash freshness checking by @jdx in [#8404](#8404) - **(tasks)** monorepo vars and per-task vars by @halms in [#8248](#8248) ### 🐛 Bug Fixes - **(aqua)** restore bin_paths disk cache with fresh_file invalidation by @jdx in [#8398](#8398) - **(idiomatic)** use generic parser for idiomatic files by @risu729 in [#8171](#8171) - **(install)** apply precompiled options to all platforms in lockfile by @jdx in [#8396](#8396) - **(install)** normalize "v" prefix when matching lockfile versions by @jdx in [#8413](#8413) - **(prepare)** improve git submodule parser and fix check_staleness error handling by @jdx in [#8412](#8412) - **(python)** respect precompiled settings in lock file generation by @jdx in [#8399](#8399) - **(python)** clarify uv_venv_auto docs + prevent uv shim recursion in venv creation by @halms in [#8402](#8402) - **(task)** remove deprecated `# mise` task header syntax by @jdx in [#8403](#8403) - **(vfox)** avoid eager metadata loading during config file detection by @jdx in [#8397](#8397) - clarify GitHub attestations to be artifact ones by @scop in [#8394](#8394) - ignore comments in idiomatic version files by @iloveitaly in [#7682](#7682) ### 🚜 Refactor - unify archive detection by @risu729 in [#8137](#8137) ### 📚 Documentation - remove duplicated docs for npm.package_manager by @risu729 in [#8414](#8414)
Two related fixes for
python.uv_venv_auto:Docs: The warning block on the Python page was misleading — it said
uv_venv_auto = trueis "deprecated", but only thetruevalue is being phased out, not the setting itself. Rewrites the warning to clarify this, and also explains the practical difference between the legacytruebehavior (exportsUV_PYTHONwith just the version string, letting uv pick any matching Python) vs the recommended approach (usingtools.python.pathto strictly bind uv to the exact mise-managed Python binary).Bug fix: When
uv_venv_auto = "create|source"is set and a mise shim foruvexists on PATH (e.g. from another project),create_python_venvwas finding the shim viawhich_non_pristine("uv"). Running the shim callsmise exec, which re-enters env resolution and callscreate_python_venvagain — causing infinite subprocess recursion and an endless stream of "mise creating venv with uv at: ..." messages.Fix adds
which_no_shims()that excludes$MISE_DATA_DIR/shimsfrom the PATH search, and uses it increate_python_venv. Also handlesOk(false)fromcreate_python_venvinuv_venv()correctly (previously fell through toload_venvon a non-existent path).