Trouble with python on Ubuntu 14.04












0















I'm using ubuntu 14.04 and I have messed up python. First, I've installed python 3.6.8, but I had some problem with it, so I moved to python 3.6.1. Only way to invoke 3.6.1 version is to use python3.6, but I need to make it work by using python.
When i try alias, it kinda works, but not everywhere.
I wanted to install ffmpeg, but when I use:



sudo add-apt-repository ppa:mc3man/trusty-media


I'm getting an error that says



    Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 11, in <module>
from softwareproperties.SoftwareProperties import SoftwareProperties, shortcut_handler
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 27, in <module>
import apt_pkg
ModuleNotFoundError: No module named 'apt_pkg'


Then, when I try to fix this with



apt-get install python-apt


I get another error



Reading package lists... Done
Building dependency tree
Reading state information... Done
python-apt is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
16 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up lsb-release (4.1+Debian11ubuntu6.2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package lsb-release (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-apt (0.9.3.5ubuntu3) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-apt (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-chardet (2.0.1-2build2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-chardet (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-colorama (0.2.5-0.1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-colorama (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-distlib (0.1.8-1ubuntu1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-distlib (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-six (1.5.2-1ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-six (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-html5lib:
python-html5lib depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-html5lib (--configure):
dependency problems - leaving unconfigured
Setting up python-pkg-resources (3.3-1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-pkg-resources (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-urllib3:
python-urllib3 depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-urllib3 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-requests:
python-requests depends on python-chardet; however:
Package python-chardet is not configured yet.
python-requests depends on python-urllib3 (>= 1.7.1); however:
Package python-urllib3 is not configured yet.

dpkg: error processing package python-requests (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-setuptools:
python-setuptools depends on python-pkg-resources (= 3.3-1ubuntu2); however:
Package python-pkg-resources is not configured yet.

dpkg: error processing package python-setuptools (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-pip:
python-pip depends on python-colorama; however:
Package python-colorama is not configured yet.
python-pip depends on python-distlib; however:
Package python-distlib is not configured yet.
python-pip depends on python-html5lib; however:
Package python-html5lib is not configured yet.
python-pip depends on python-pkg-resources; however:
Package python-pkg-resources is not configured yet.
python-pip depends on python-requests; however:
Package python-requests is not configured yet.
python-pip depends on python-setuptools (>= 0.6c1); however:
Package python-setuptools is not configured yet.
python-pip depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-pip (--configure):
dependency problems - leaving unconfigured
Setting up python-wheel (0.24.0-1~ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-wheel (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of unattended-upgrades:
unattended-upgrades depends on lsb-release; however:
Package lsb-release is not configured yet.

dpkg: error processing package unattended-upgrades (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python3-software-properties:
python3-software-properties depends on lsb-release; however:
Package lsb-release is not configured yet.
python3-software-properties depends on unattended-upgrades; however:
Package unattended-upgrades is not configured yet.

dpkg: error processing package python3-software-properties (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of software-properties-common:
software-properties-common depends on python3-software-properties (= 0.92.37.8); however:
Package python3-software-properties is not configured yet.

dpkg: error processing package software-properties-common (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
lsb-release
python-apt
python-chardet
python-colorama
python-distlib
python-six
python-html5lib
python-pkg-resources
python-urllib3
python-requests
python-setuptools
python-pip
python-wheel
unattended-upgrades
python3-software-properties
software-properties-common
E: Sub-process /usr/bin/dpkg returned an error code (1)


And I'm stuck at this point. I think that when I run those commands, it's invoking python 3.6.8, but I want to use 3.6.1 version. What can I do?










share|improve this question























  • What's wrong with 3.6.8? That seems like the actual issue to solve. 14.04 only provides 3.4.0. How did you install 3.6.8 or 3.6.1? 14.04 end of life is in 2019-04. Can you not upgrade? 18.04 LTS provides 3.6.5.

    – llogan
    Feb 25 at 19:07


















0















I'm using ubuntu 14.04 and I have messed up python. First, I've installed python 3.6.8, but I had some problem with it, so I moved to python 3.6.1. Only way to invoke 3.6.1 version is to use python3.6, but I need to make it work by using python.
When i try alias, it kinda works, but not everywhere.
I wanted to install ffmpeg, but when I use:



sudo add-apt-repository ppa:mc3man/trusty-media


I'm getting an error that says



    Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 11, in <module>
from softwareproperties.SoftwareProperties import SoftwareProperties, shortcut_handler
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 27, in <module>
import apt_pkg
ModuleNotFoundError: No module named 'apt_pkg'


Then, when I try to fix this with



apt-get install python-apt


I get another error



Reading package lists... Done
Building dependency tree
Reading state information... Done
python-apt is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
16 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up lsb-release (4.1+Debian11ubuntu6.2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package lsb-release (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-apt (0.9.3.5ubuntu3) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-apt (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-chardet (2.0.1-2build2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-chardet (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-colorama (0.2.5-0.1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-colorama (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-distlib (0.1.8-1ubuntu1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-distlib (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-six (1.5.2-1ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-six (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-html5lib:
python-html5lib depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-html5lib (--configure):
dependency problems - leaving unconfigured
Setting up python-pkg-resources (3.3-1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-pkg-resources (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-urllib3:
python-urllib3 depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-urllib3 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-requests:
python-requests depends on python-chardet; however:
Package python-chardet is not configured yet.
python-requests depends on python-urllib3 (>= 1.7.1); however:
Package python-urllib3 is not configured yet.

dpkg: error processing package python-requests (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-setuptools:
python-setuptools depends on python-pkg-resources (= 3.3-1ubuntu2); however:
Package python-pkg-resources is not configured yet.

dpkg: error processing package python-setuptools (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-pip:
python-pip depends on python-colorama; however:
Package python-colorama is not configured yet.
python-pip depends on python-distlib; however:
Package python-distlib is not configured yet.
python-pip depends on python-html5lib; however:
Package python-html5lib is not configured yet.
python-pip depends on python-pkg-resources; however:
Package python-pkg-resources is not configured yet.
python-pip depends on python-requests; however:
Package python-requests is not configured yet.
python-pip depends on python-setuptools (>= 0.6c1); however:
Package python-setuptools is not configured yet.
python-pip depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-pip (--configure):
dependency problems - leaving unconfigured
Setting up python-wheel (0.24.0-1~ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-wheel (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of unattended-upgrades:
unattended-upgrades depends on lsb-release; however:
Package lsb-release is not configured yet.

dpkg: error processing package unattended-upgrades (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python3-software-properties:
python3-software-properties depends on lsb-release; however:
Package lsb-release is not configured yet.
python3-software-properties depends on unattended-upgrades; however:
Package unattended-upgrades is not configured yet.

dpkg: error processing package python3-software-properties (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of software-properties-common:
software-properties-common depends on python3-software-properties (= 0.92.37.8); however:
Package python3-software-properties is not configured yet.

dpkg: error processing package software-properties-common (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
lsb-release
python-apt
python-chardet
python-colorama
python-distlib
python-six
python-html5lib
python-pkg-resources
python-urllib3
python-requests
python-setuptools
python-pip
python-wheel
unattended-upgrades
python3-software-properties
software-properties-common
E: Sub-process /usr/bin/dpkg returned an error code (1)


And I'm stuck at this point. I think that when I run those commands, it's invoking python 3.6.8, but I want to use 3.6.1 version. What can I do?










share|improve this question























  • What's wrong with 3.6.8? That seems like the actual issue to solve. 14.04 only provides 3.4.0. How did you install 3.6.8 or 3.6.1? 14.04 end of life is in 2019-04. Can you not upgrade? 18.04 LTS provides 3.6.5.

    – llogan
    Feb 25 at 19:07
















0












0








0








I'm using ubuntu 14.04 and I have messed up python. First, I've installed python 3.6.8, but I had some problem with it, so I moved to python 3.6.1. Only way to invoke 3.6.1 version is to use python3.6, but I need to make it work by using python.
When i try alias, it kinda works, but not everywhere.
I wanted to install ffmpeg, but when I use:



sudo add-apt-repository ppa:mc3man/trusty-media


I'm getting an error that says



    Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 11, in <module>
from softwareproperties.SoftwareProperties import SoftwareProperties, shortcut_handler
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 27, in <module>
import apt_pkg
ModuleNotFoundError: No module named 'apt_pkg'


Then, when I try to fix this with



apt-get install python-apt


I get another error



Reading package lists... Done
Building dependency tree
Reading state information... Done
python-apt is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
16 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up lsb-release (4.1+Debian11ubuntu6.2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package lsb-release (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-apt (0.9.3.5ubuntu3) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-apt (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-chardet (2.0.1-2build2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-chardet (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-colorama (0.2.5-0.1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-colorama (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-distlib (0.1.8-1ubuntu1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-distlib (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-six (1.5.2-1ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-six (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-html5lib:
python-html5lib depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-html5lib (--configure):
dependency problems - leaving unconfigured
Setting up python-pkg-resources (3.3-1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-pkg-resources (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-urllib3:
python-urllib3 depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-urllib3 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-requests:
python-requests depends on python-chardet; however:
Package python-chardet is not configured yet.
python-requests depends on python-urllib3 (>= 1.7.1); however:
Package python-urllib3 is not configured yet.

dpkg: error processing package python-requests (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-setuptools:
python-setuptools depends on python-pkg-resources (= 3.3-1ubuntu2); however:
Package python-pkg-resources is not configured yet.

dpkg: error processing package python-setuptools (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-pip:
python-pip depends on python-colorama; however:
Package python-colorama is not configured yet.
python-pip depends on python-distlib; however:
Package python-distlib is not configured yet.
python-pip depends on python-html5lib; however:
Package python-html5lib is not configured yet.
python-pip depends on python-pkg-resources; however:
Package python-pkg-resources is not configured yet.
python-pip depends on python-requests; however:
Package python-requests is not configured yet.
python-pip depends on python-setuptools (>= 0.6c1); however:
Package python-setuptools is not configured yet.
python-pip depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-pip (--configure):
dependency problems - leaving unconfigured
Setting up python-wheel (0.24.0-1~ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-wheel (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of unattended-upgrades:
unattended-upgrades depends on lsb-release; however:
Package lsb-release is not configured yet.

dpkg: error processing package unattended-upgrades (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python3-software-properties:
python3-software-properties depends on lsb-release; however:
Package lsb-release is not configured yet.
python3-software-properties depends on unattended-upgrades; however:
Package unattended-upgrades is not configured yet.

dpkg: error processing package python3-software-properties (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of software-properties-common:
software-properties-common depends on python3-software-properties (= 0.92.37.8); however:
Package python3-software-properties is not configured yet.

dpkg: error processing package software-properties-common (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
lsb-release
python-apt
python-chardet
python-colorama
python-distlib
python-six
python-html5lib
python-pkg-resources
python-urllib3
python-requests
python-setuptools
python-pip
python-wheel
unattended-upgrades
python3-software-properties
software-properties-common
E: Sub-process /usr/bin/dpkg returned an error code (1)


And I'm stuck at this point. I think that when I run those commands, it's invoking python 3.6.8, but I want to use 3.6.1 version. What can I do?










share|improve this question














I'm using ubuntu 14.04 and I have messed up python. First, I've installed python 3.6.8, but I had some problem with it, so I moved to python 3.6.1. Only way to invoke 3.6.1 version is to use python3.6, but I need to make it work by using python.
When i try alias, it kinda works, but not everywhere.
I wanted to install ffmpeg, but when I use:



sudo add-apt-repository ppa:mc3man/trusty-media


I'm getting an error that says



    Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 11, in <module>
from softwareproperties.SoftwareProperties import SoftwareProperties, shortcut_handler
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 27, in <module>
import apt_pkg
ModuleNotFoundError: No module named 'apt_pkg'


Then, when I try to fix this with



apt-get install python-apt


I get another error



Reading package lists... Done
Building dependency tree
Reading state information... Done
python-apt is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
16 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up lsb-release (4.1+Debian11ubuntu6.2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package lsb-release (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-apt (0.9.3.5ubuntu3) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-apt (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-chardet (2.0.1-2build2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-chardet (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-colorama (0.2.5-0.1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-colorama (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-distlib (0.1.8-1ubuntu1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-distlib (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up python-six (1.5.2-1ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-six (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-html5lib:
python-html5lib depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-html5lib (--configure):
dependency problems - leaving unconfigured
Setting up python-pkg-resources (3.3-1ubuntu2) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-pkg-resources (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-urllib3:
python-urllib3 depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-urllib3 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-requests:
python-requests depends on python-chardet; however:
Package python-chardet is not configured yet.
python-requests depends on python-urllib3 (>= 1.7.1); however:
Package python-urllib3 is not configured yet.

dpkg: error processing package python-requests (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-setuptools:
python-setuptools depends on python-pkg-resources (= 3.3-1ubuntu2); however:
Package python-pkg-resources is not configured yet.

dpkg: error processing package python-setuptools (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python-pip:
python-pip depends on python-colorama; however:
Package python-colorama is not configured yet.
python-pip depends on python-distlib; however:
Package python-distlib is not configured yet.
python-pip depends on python-html5lib; however:
Package python-html5lib is not configured yet.
python-pip depends on python-pkg-resources; however:
Package python-pkg-resources is not configured yet.
python-pip depends on python-requests; however:
Package python-requests is not configured yet.
python-pip depends on python-setuptools (>= 0.6c1); however:
Package python-setuptools is not configured yet.
python-pip depends on python-six; however:
Package python-six is not configured yet.

dpkg: error processing package python-pip (--configure):
dependency problems - leaving unconfigured
Setting up python-wheel (0.24.0-1~ubuntu1.1) ...
Traceback (most recent call last):
File "/usr/bin/pycompile", line 35, in <module>
from debpython.version import SUPPORTED, debsorted, vrepr,
File "/usr/share/python/debpython/version.py", line 24, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
dpkg: error processing package python-wheel (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of unattended-upgrades:
unattended-upgrades depends on lsb-release; however:
Package lsb-release is not configured yet.

dpkg: error processing package unattended-upgrades (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python3-software-properties:
python3-software-properties depends on lsb-release; however:
Package lsb-release is not configured yet.
python3-software-properties depends on unattended-upgrades; however:
Package unattended-upgrades is not configured yet.

dpkg: error processing package python3-software-properties (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of software-properties-common:
software-properties-common depends on python3-software-properties (= 0.92.37.8); however:
Package python3-software-properties is not configured yet.

dpkg: error processing package software-properties-common (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
lsb-release
python-apt
python-chardet
python-colorama
python-distlib
python-six
python-html5lib
python-pkg-resources
python-urllib3
python-requests
python-setuptools
python-pip
python-wheel
unattended-upgrades
python3-software-properties
software-properties-common
E: Sub-process /usr/bin/dpkg returned an error code (1)


And I'm stuck at this point. I think that when I run those commands, it's invoking python 3.6.8, but I want to use 3.6.1 version. What can I do?







14.04 apt python python3 ffmpeg






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Feb 23 at 3:20









ZedenZeden

11




11













  • What's wrong with 3.6.8? That seems like the actual issue to solve. 14.04 only provides 3.4.0. How did you install 3.6.8 or 3.6.1? 14.04 end of life is in 2019-04. Can you not upgrade? 18.04 LTS provides 3.6.5.

    – llogan
    Feb 25 at 19:07





















  • What's wrong with 3.6.8? That seems like the actual issue to solve. 14.04 only provides 3.4.0. How did you install 3.6.8 or 3.6.1? 14.04 end of life is in 2019-04. Can you not upgrade? 18.04 LTS provides 3.6.5.

    – llogan
    Feb 25 at 19:07



















What's wrong with 3.6.8? That seems like the actual issue to solve. 14.04 only provides 3.4.0. How did you install 3.6.8 or 3.6.1? 14.04 end of life is in 2019-04. Can you not upgrade? 18.04 LTS provides 3.6.5.

– llogan
Feb 25 at 19:07







What's wrong with 3.6.8? That seems like the actual issue to solve. 14.04 only provides 3.4.0. How did you install 3.6.8 or 3.6.1? 14.04 end of life is in 2019-04. Can you not upgrade? 18.04 LTS provides 3.6.5.

– llogan
Feb 25 at 19:07












0






active

oldest

votes











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1120523%2ftrouble-with-python-on-ubuntu-14-04%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded




















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1120523%2ftrouble-with-python-on-ubuntu-14-04%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

flock() on closed filehandle LOCK_FILE at /usr/bin/apt-mirror

Mangá

 ⁒  ․,‪⁊‑⁙ ⁖, ⁇‒※‌, †,⁖‗‌⁝    ‾‸⁘,‖⁔⁣,⁂‾
”‑,‥–,‬ ,⁀‹⁋‴⁑ ‒ ,‴⁋”‼ ⁨,‷⁔„ ‰′,‐‚ ‥‡‎“‷⁃⁨⁅⁣,⁔
⁇‘⁔⁡⁏⁌⁡‿‶‏⁨ ⁣⁕⁖⁨⁩⁥‽⁀  ‴‬⁜‟ ⁃‣‧⁕‮ …‍⁨‴ ⁩,⁚⁖‫ ,‵ ⁀,‮⁝‣‣ ⁑  ⁂– ․, ‾‽ ‏⁁“⁗‸ ‾… ‹‡⁌⁎‸‘ ‡⁏⁌‪ ‵⁛ ‎⁨ ―⁦⁤⁄⁕