Comment 8 for bug 1631367

Revision history for this message
Frankie Robertson (frankie-q) wrote :

This shouldn't be "priority low". Apport breaks the Python 3.6 package. At least all desktop users trying to use Python 3.6 should be affected.

To summarise the problem, python3-apt has a C module which is only compiled for Python 3.5, but Python 3.6 needs it to run the apport.

Some possible possible workarounds:
* Get rid of the symlink: rm /usr/lib/python3.6/sitecustomize.py

* Change /etc/sitecustomize.py to not install the hook if apt_pkg is available

    # install the apport exception handler if available
    try:
        import apport_python_hook
        import apt_pkg # <-- Add this line
    except ImportError:
        pass
    else:
        apport_python_hook.install()

* Install the apt module

    $ sudo apt install python3.6-dev libapt-pkg-dev python3-distutils-extra # Get build requirements
    $ wget https://bootstrap.pypa.io/get-pip.py # Get pip
    $ python3.6 get-pip.py
    $ python3.6 /usr/bin/pip3 install http://launchpad.net/python-distutils-extra/trunk/2.28/+download/python-distutils-extra-2.28.tar.gz # install apt requirments
    $ python3.6 /usr/bin/pip3 install https://launchpad.net/ubuntu/+archive/primary/+files/python-apt_1.1.0~beta1build1.tar.xz # install apt package for Python 3.6