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

Fix suffixed venv uninstall, and fix suffixed venv install summary. #653

Merged
merged 11 commits into from
Mar 25, 2021

Conversation

itsayellow
Copy link
Contributor

  • I have added an entry to docs/changelog.md

Summary of changes

Closes #652 .

On non-symlinked filesystems like typical Windows filesystems, pipx didn't actually delete apps in the local binary dir associated with a suffixed venv. This fixes that.

Also, when summarizing an install, on a non-symlink filesystem (Windows) we would normally not properly handle the installed binaries, reporting each app with (symlink missing or pointing to unexpected location)

Also updated tests to test the functionality that we now do correctly.

Test plan

On Windows!

Install

This PR:

> pipx install pycowsay --suffix _a
done!
creating virtual environment...
installing pycowsay...
  installed package pycowsay 0.0.0.1 (pycowsay_a), Python 3.9.1
  These apps are now globally available
    - pycowsay_a.exe

pipx 0.16.1.0

> pipx install pycowsay --suffix _a
  Overwriting file C:\Users\mclapp\.local\bin\pycowsay_a.exe with C:\Users\mclapp\.local\pipx\venvs\pycowsay-a\Scripts\pycowsay.exe
done!
creating virtual environment...
installing pycowsay...
  installed package pycowsay 0.0.0.1 (pycowsay_a), Python 3.9.1
    - pycowsay_a.exe (symlink missing or pointing to unexpected location)

Uninstall

This PR:

> pipx uninstall pycowsay_a
uninstalled pycowsay_a!
> ls ~/.local/bin/pycowsay_a.exe
ls: cannot access '/c/Users/mclapp/.local/bin/pycowsay_a.exe': No such file or directory

pipx 0.16.1.0

> pipx uninstall pycowsay_a
uninstalled pycowsay_a!
> ls ~/.local/bin/pycowsay_a.exe
/c/Users/mclapp/.local/bin/pycowsay_a.exe*

@itsayellow itsayellow merged commit 13b6a27 into pypa:master Mar 25, 2021
@itsayellow itsayellow deleted the uninstall-suffix branch March 25, 2021 05:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Windows: venv with suffix doesn't uninstall associated apps in bin directory
1 participant