I tried recreating the bug as described in the description and py_compile.py in the version of python3.5 on Xenial does not import _remove_dead_weakref so there is not Traceback when trying to reinstall python3.5 after installing python3.5 in /usr/local/bin. However, its still possible to verify the fix by confirming that the file /var/lib/dpkg/python3.5.postinst and other postinst scripts now use the full path to python3.5 when calling py_compile.py e.g.:
bdmurray@clean-xenial-amd64:/var/lib/dpkg/info$ grep "py_compile.py" *.postinst python2.7-minimal.postinst: python2.7 -E -S /usr/lib/python2.7/py_compile.py $files python2.7-minimal.postinst: python2.7 -E -S -O /usr/lib/python2.7/py_compile.py $files python2.7.postinst: python2.7 -E -S /usr/lib/python2.7/py_compile.py $files python2.7.postinst: python2.7 -E -S -O /usr/lib/python2.7/py_compile.py $files python3.5-minimal.postinst: /usr/bin/python3.5 -E -S /usr/lib/python3.5/py_compile.py $files python3.5-minimal.postinst: /usr/bin/python3.5 -E -S -O /usr/lib/python3.5/py_compile.py $files python3.5.postinst: /usr/bin/python3.5 -E -S /usr/lib/python3.5/py_compile.py $files python3.5.postinst: /usr/bin/python3.5 -E -S -O /usr/lib/python3.5/py_compile.py $files We can see this is fixed for python3.5 but not python2.7 so setting to verification-done for xenial. ** Tags removed: verification-needed-xenial ** Tags added: verification-done-xenial -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1682934 Title: python3 in /usr/local/bin can cause python3 packages to fail to install To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/python2.7/+bug/1682934/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs