add-apt-repository fails due to softwareproperties error

Bug #1048733 reported by ԜаӀtеr Ⅼарсһуnѕkі
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
software-properties (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

$ sudo add-apt-repository ppa:lubuntu-dev/lubuntu-daily
Traceback (most recent call last):
  File "/usr/bin/add-apt-repository", line 10, in <module>
    from softwareproperties.SoftwareProperties import SoftwareProperties
ImportError: No module named softwareproperties.SoftwareProperties

I tried other PPAs and had the same error so it seems to be universal.

Interestingly trying to add manually in Settings → Repository just results in a notice saying that repos have changed and you need to reload. It doesn't actually get to the point where you add repos. That may be a related issue so I will file a separate bug and link here and vice versa.

ProblemType: Bug
DistroRelease: Ubuntu 12.10
Package: python-software-properties 0.92.1
ProcVersionSignature: Ubuntu 3.4.0-5.11-generic 3.4.0
Uname: Linux 3.4.0-5-generic i686
ApportVersion: 2.1.1-0ubuntu2
Architecture: i386
Date: Mon Sep 10 10:15:50 2012
InstallationMedia: Lubuntu 12.04 "Precise Pangolin" - Alpha i386 (20120215)
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=en_US:en
 TERM=screen
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: software-properties
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
ԜаӀtеr Ⅼарсһуnѕkі (wxl) wrote :
Revision history for this message
ԜаӀtеr Ⅼарсһуnѕkі (wxl) wrote :
Revision history for this message
ԜаӀtеr Ⅼарсһуnѕkі (wxl) wrote :

i should probably call this "fix committed" rather than invalid since something has changed since we've updated to 0.92.6 but no problems anymore. my guess is that the changes affecting the synaptic bug had a trickle down effect.

Changed in software-properties (Ubuntu):
status: New → Invalid
Revision history for this message
Pavlo Bohmat (bohm) wrote :

~$ sudo add-apt-repository ppa:caffeine-developers/ppa
[sudo] password for <user>:
Traceback (most recent call last):
  File "/usr/bin/add-apt-repository", line 11, in <module>
    from softwareproperties.SoftwareProperties import SoftwareProperties, shortcut_handler
ImportError: No module named 'softwareproperties.SoftwareProperties'

Ubuntu 14.04

Revision history for this message
Pavlo Bohmat (bohm) wrote :

Ubuntu 14.04 + synaptic 0.81.1 -> Repositories:

Traceback (most recent call last):
  File "/usr/bin/software-properties-gtk", line 37, in <module>
    from softwareproperties.gtk.SoftwarePropertiesGtk import SoftwarePropertiesGtk
  File "/usr/lib/python3/dist-packages/softwareproperties/gtk/SoftwarePropertiesGtk.py", line 44, in <module>
    from .DialogMirror import DialogMirror
  File "/usr/lib/python3/dist-packages/softwareproperties/gtk/DialogMirror.py", line 31, in <module>
    from softwareproperties.MirrorTest import MirrorTest
ImportError: No module named 'softwareproperties.MirrorTest'

Revision history for this message
Michael Vogt (mvo) wrote :

@Pavlo: this sounds like there is something wrong with your software-properites package install. You may want to run "sudo apt-get install --reinstall python3-software-properties"

Revision history for this message
Junlan Liu (pumpkin880201) wrote :

@Michael, that didn't work for me. The error showed up after I installed python3.5 from source.
$ wget http://python.org/ftp/python/3.5.2/Python-3.5.2.tar.xz
$ tar xpvf Python-3.5.2.tar.xz
$ cd Python-3.5.2
$ ./configure --prefix=/usr
$ make
$ make install

If I link python3 to python3.4, then it starts working again
$ sudo rm /usr/bin/python3
$ sudo ln -s /usr/bin/python3.4 /usr/bin/python3

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.