Conversation
…ompletion
Version auto-completion ('ide install python 3.' + Tab) used to call the
auto-installing runTool variant in PythonRepository.fetchUvPythonList(),
which silently installed or upgraded uv in the background just to list the
available python versions.
* PythonRepository.fetchUvPythonList() now guards on uv.isInstalled(): if
uv is missing it logs a warning and returns an empty list (no download).
* Python.completeRequest() ensures uv is installed on the install path
before the python version is resolved (the version list comes exclusively
from 'uv python list' and resolution happens before the uv dependency
would normally be installed).
* Added testGetSortedVersionsIsEmptyWhenUvNotInstalled for the guard.
- shortend javadoc
Collaborator
Coverage Report for CI Build 35612692096Coverage decreased (-0.001%) to 74.245%Details
Uncovered ChangesNo uncovered changes found. Coverage Regressions21 previously-covered lines in 3 files lost coverage.
Coverage Stats💛 - Coveralls |
…b-comletion-for-ide-install-python-triggers-uv-installation
- add changelog entry
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.
This PR fixes #2484
Implemented changes:
fetchUvpythonList()has been change to only run the command and does not trigger an installation bevor running the command if tool is not installed or update is availablecompleteRequest(ToolInstallationRequest request)toPython.javato ensure uv is installed bevor installing Python.Note
Completion no longer installs uv implicitly. Since warnings are currently not surfaced reliably from the completion flow, no user-facing message is shown. Suggestions for a cleaner approach are welcome.
Testing instructions
Please add conscise, understandable instructions on how a reviewer can test/verify the functionality of your contribution here:
mvn clean testin cli module../build-local-dev.sh.projects/<my-project>/softwarethat uv and python is not installed, otherwise delete both.ide install python 3.and use tab for autocompletion.3.*or3.*!.6 Install python
ide install pythonand verifyuvis still preinstalled bevor python ist installed.ide install python 3.again and use tab for autocompletion nowuvis installed and show all possible options.Checklist for this PR
Make sure everything is checked before merging this PR. For further info please also see
our DoD.
mvn clean testlocally all tests pass and build is successful#«issue-id»: «brief summary»(e.g.#921: fixed setup.batand notfeature/921 fixed setup.bat). If no issue ID exists, title only.In Progressand assigned to you or there is no issue (might happen for very small PRs)with
internalpom.xmlfiles or otherwise if runtime dependencies changed, you have updated our LICENSE.asciidoc