pip: return Command 'lsb_release -a' returned non-zero exit status 1.
- Pip version: pip 9.0.1
- Python version: python 3.6.3
- Operating system: debian 9.3
Description:
when I’m installing pyssim using pip pip is intalled and used under anaconda
What I’ve run:
pip install pyssim
Exception:
Traceback (most recent call last):
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/commands/install.py", line 272, in run
with self._build_session(options) as session:
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/basecommand.py", line 72, in _build_session
insecure_hosts=options.trusted_hosts,
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/download.py", line 329, in __init__
self.headers["User-Agent"] = user_agent()
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/download.py", line 93, in user_agent
from pip._vendor import distro
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/_vendor/distro.py", line 1050, in <module>
_distro = LinuxDistribution()
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/_vendor/distro.py", line 594, in __init__
if include_lsb else {}
File "/home/wujunde/anaconda3/lib/python3.6/site-packages/pip/_vendor/distro.py", line 931, in _get_lsb_release_info
raise subprocess.CalledProcessError(code, cmd, stdout, stderr)
subprocess.CalledProcessError: Command 'lsb_release -a' returned non-zero exit status 1.
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 4
- Comments: 15 (4 by maintainers)
sudo rm /usr/bin/lsb_release
It resolved my problem.
sudo mv /usr/bin/lsb_release /usr/bin/lsb_release_back
just to be on the safe sideThanks for @pfmoore, I fixed it. The problem is all about lsb_release, nothing to do with pip My python3.6 doesn’t have lsb_release pack (don’t know why) I just change my ptyhon2.7 to run lsb_release in /usr/bin/lsb_release FROM: #! /usr/bin/python3 -Es TO: #! /usr/bin/python2.7 -Es
Hello, I also managed to get a similar error. I have Python2.7 and Python3 on my Ubuntu 16.04 but am unable to figure out why this error is popping when I try to use pip and ppa to add repositories. What could be the problem here and how could I resolve it. Here’s the trace:
Thanks for your time.