Skip to content

uv tool integration #588

@MaKaNu

Description

@MaKaNu

Prerequisites

  • This was not already reported in the past (duplicate check)
  • It does reproduce it with code from main branch (latest unreleased version)
  • I include a minimal example for reproducing the bug
  • The bug is not trivial, as for those a direct pull-request is preferred
  • Running pip check does not report any conflicts
  • I was able to reproduce the issue on a different machine
  • The issue is not specific to any driver other than 'default' one

Environment

$ uvx --from ansible-dev-tools adt --version
ansible-builder                          3.1.0
ansible-core                             2.19.0
ansible-creator                          25.7.0
ansible-dev-environment                  25.5.0
ansible-dev-tools                        25.5.2
ansible-lint                             25.6.1
ansible-navigator                        25.5.0
ansible-sign                             0.1.2
molecule                                 25.6.0
pytest-ansible                           25.6.3
tox-ansible                              25.5.5

What happened

Instead of using a venv or other method, I tried to utilize uv tool install ansible-dev-tools to work with adt.

The first thing I noticed was, that adt is installed via symlink into my ~/.local/bin/ directory. I do not understand uv tool enough, but I think this is the result of pyproject.toml#L34-L36

But this also results in not having the other binaries in path, instead only on ~/.local/share/uv/tools/ansible-dev-tools/bin which is not on path.

I think running the other binaries via additional tool like uvx --from ansible-core ansible --version, destroys some purpose of adt, I think.

I am not sure if it is possible to expose the other binaries the same way adt is exposed.

Reproducing example

$ uv tool install ansible-dev-tools

$ adt --version
ansible-builder                          3.1.0
ansible-core                             2.19.0
ansible-creator                          25.7.0
ansible-dev-environment                  25.5.0
ansible-dev-tools                        25.5.2
ansible-lint                             25.6.1
ansible-navigator                        25.5.0
ansible-sign                             0.1.2
molecule                                 25.6.0
pytest-ansible                           25.6.3
tox-ansible                              25.5.5

$ ansible --version
bash: ansible: command not found

$ which adt
/home/user/.local/bin/adt

$ ls -l $(which adt)
lrwxrwxrwx 1 user user 72 Jul 28 11:05 /home/user/.local/bin/adt -> /home/user/.local/share/uv/tools/ansible-dev-tools/bin/adt

ls /home/user/.local/share/uv/tools/ansible-dev-tools/bin/ | grep ansible
ansible
ansible-builder
ansible-config
ansible-console
ansible-creator
ansible-doc
ansible-galaxy
ansible-inventory
ansible-lint
ansible-navigator
ansible-playbook
ansible-pull
ansible-runner
ansible-sign
ansible-test
ansible-vault

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions