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

The 'cmd2' distribution was not found and is required by the application #39

Closed
iamtalhaasghar opened this issue May 28, 2021 · 8 comments · May be fixed by #45
Closed

The 'cmd2' distribution was not found and is required by the application #39

iamtalhaasghar opened this issue May 28, 2021 · 8 comments · May be fixed by #45

Comments

@iamtalhaasghar
Copy link

The issue is caused because cmd2 is not installed with pip-autoremove

Solution:

  • Add cmd2 as a dependency in setup.py file so cmd2 is installed automatically and this will fix the issue.

For now, any user who is facing this issue can manually install cmd2 with following command:
pip install cmd2

@X-m7
Copy link

X-m7 commented Jul 4, 2021

In my case in addition to cmd2 I also needed to install pyyaml.

@gardenappl
Copy link

Also brotli and email-validator...

@tresni
Copy link
Contributor

tresni commented Sep 16, 2021

cmd2 is not a requirement of pip-autoremove, nor are any of the packages mentioned here (pyyaml, brotli, or email-validator.) The only requirements for pip-autoremove are pip and setuptools which are basically defaults (though not actually part of the stdlib. Checkout my fork for an updated version of pip-autoremove that fixes many of the issues here.

@tresni
Copy link
Contributor

tresni commented Sep 17, 2021

Should be addressed by #42 and the new release, please close if that resolves your issue.

@ajslater
Copy link

ajslater commented Sep 17, 2021

I get this message:

The 'python-lsp-server' distribution was not found and is required by the application

with the new version. However:

  1. I can't see any functionality that's missing from pip-autoremove without that package. I just get the warning. Like you say, it doesn't appear to be a real requirement.
  2. Installing python-lsp-server does indeed make the warning go away.

It feels like this warning is not about pip-autoremove itself, but a side effect of checking one of the many installed packages. Is the cmd2 package warning in the title of this issue the same thing? A good fix for this would be for pip-autoremove to detect when this is happening (possibly difficult) and identify the package that is complaining.

@ajslater
Copy link

ajslater commented Sep 17, 2021

Similarly, I get these helpful, but ambiguous messages from pip-autoremove:

jedi 0.18.0 is installed but jedi<0.18.0,>=0.17.2 is required
Redoing requirement with just package name...
PyPDF2 1.26.0 is installed but PyPDF2==1.24 is required
Redoing requirement with just package name...
unrar-cffi 0.2.1 is installed but unrar-cffi==0.1.0a5 is required
Redoing requirement with just package name...
natsort 7.1.1 is installed but natsort==3.5.2 is required
Redoing requirement with just package name...

Which package wants an older version of jedi? If a subprocess is producing that message then, again, this gets difficult, but if pip-autoremove is creating this message then mentioning which package wants an older version would be helpful.

@tresni
Copy link
Contributor

tresni commented Sep 18, 2021 via email

@tresni
Copy link
Contributor

tresni commented Oct 3, 2021

Please test with #45 and let me know if that helps make it more obvious what is going on

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 a pull request may close this issue.

5 participants