58
sudo apt-get install python-software-properties
Reading package lists... Done
Building dependency tree... Done
Package python-software-properties is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:

 software-properties-common

E: Package 'python-software-properties' has no installation candidate

How can i fix this error?

6 Answers 6

71

Install software-properties-common by running,

sudo apt-get install software-properties-common

software-properties-common package is an alternate one for python-software-properties.

for <= 12.04

sudo apt-get install python-software-properties

for >= 12.10

sudo apt-get install software-properties-common
5
  • 2
    This is working. but still the sudo apt-get install python-software-properties is not working.
    – user238511
    Commented Feb 19, 2014 at 6:16
  • 2
    python-software-properties package will only be available for the versions below 12.04. Commented Feb 19, 2014 at 6:17
  • @AvinashRaj and what would replace it? Commented Nov 4, 2014 at 18:49
  • 7
    If you found this when trying to install torch, you'll need to comment the two lines involving python-software-properties in torch/install-deps after installing software-properties-common.
    – cag51
    Commented Aug 9, 2018 at 18:30
  • On Ubuntu 16.04, dpkg --listfiles python-properties-common and dpkg --listfiles software-properties-common indicates that python-properties-common adds files for only Python version 2.7. And, that software-properties-common provides files for Python 3. Commented Feb 7, 2019 at 19:46
11

I had this issue on Ubuntu 18.04

Tried several way finally this fixed my issue

sudo apt --fix-broken install python-pycurl python-apt
1
  • Thank you so much. I have tried so many solution (except the one that leads user to chaos: apt-get upgrade). And finally yours is the solution that worked for me. I guess the apt package was broken somewhere..
    – Long
    Commented Sep 3, 2020 at 11:04
6

I was getting started with the torch and faced the error.
Here is how I got it resolved.

  1. goto

    Home -> Torch -> Open install-deps

    find the keyword python-software-properties and replace it with software-python-common, save and exit.

  2. install the software-python-common with the command

    sudo apt-get install software-properties-common 
    
  3. run the command

    cd ~/torch; bash install-deps;
    

You are done!!

2
  • 2
    you made a typo in: software-python-common (should be software-properties-common)
    – HongboZhu
    Commented Jan 24, 2019 at 12:27
  • Please use software-properties-common instead of software-python-common it works like a charm !
    – Spark
    Commented Apr 12, 2019 at 5:35
1

In the executable install-deps within ~/torch, you need to edit it so that every instance of python-software-properties should be software-properties-common

An easy solution that worked for me would be to just run this simple python3 script:

with open(PATH_TO_<install-deps>, "r") as f:
    text = f.read()


change = text.replace("python-software-properties", "software-properties-common")


with open(PATH_TO_<install-deps>, "w") as f:
    f.write(change)
0

This is my 1st post and I have only used linux for a few weeks so please go easy on me =].

If ymin's method hits an error of

root@my32bitbox:~# sudo apt-get install python-software-properties git-core. Reading package lists... Done Building dependency tree
Reading state information... Done Package python-software-properties is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source However the following packages replace it:
software-properties-common

... this slightly tweaked line worked for me (note: if it makes any difference...I needed it to install 32-bit dependencies for my own wine build)

> sudo apt-get install software-properties-common git-core
-1

I also got the same error. Open terminal and type below command

sudo apt-get install -y software-properties-common

then, this

sudo apt-get install -y python-software-properties

I hope this will work. It worked in my system.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .