Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pipx uninject leaves behind broken links for dependency apps in ~/.local/bin #1364

Open
doolio opened this issue Apr 23, 2024 · 0 comments
Open
Labels
bug Something isn't working

Comments

@doolio
Copy link

doolio commented Apr 23, 2024

Describe the bug

When uninjecting a dependency (which had its own dependencies apps exposed through --include-deps) from an installed package the dependency and the dependency's dependencies apps are removed as expected but broken links for the dependency's dependencies apps remain in ~/.local/bin.

How to reproduce

  1. Install a package e.g. pipx install python-lsp-server
  2. Inject a package (with dependency app(s)) into the venv created for the package installed in step 1 and expose the app(s)
    e.g. pipx inject --include-deps python-lsp-server python-lsp-ruff (python-lsp-ruff has a dependency on ruff)
  3. pipx list --include-injected shows:
   package python-lsp-server 1.11.0, installed using Python 3.12.2
    - pylsp
    - ruff
    Injected Packages:
      - python-lsp-ruff 2.2.0
  1. Remove the package injected in step 2 e.g. pipx uninject python-lsp-server python-lsp-ruff
  2. pipx list --include-injected shows:
   package python-lsp-server 1.11.0, installed using Python 3.12.2
    - pylsp
    - ruff

Notice, ruff is still listed as exposed but it is not.

  1. which ruffgives bash: type: ruff: not found and ~/.local/bin shows:

image

Expected behavior

The links to the dependency apps should be removed if the uninject --leave-deps option is not used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants