python3 package on 20.04 is missing important sysconfig patch from debian

Bug #2039511 reported by Adrian Insaurralde Avalos
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
python3.8 (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

please update the python 3 package and add https://salsa.debian.org/cpython-team/python3/-/blob/python3.8/debian/patches/sysconfig-debian-schemes.diff

without it sysconfig gives incorrect paths for python paths, forcing people to use distutils instead, however distutils has been deprecated in 3.10 and removed from python 3.12 making it difficult to support both python 3.12 and ubuntu 20.04 at the same time.

> lsb_release -rd
Description: Ubuntu 20.04.6 LTS
Release: 20.04

> apt-cache policy python3
python3:
  Installed: 3.8.2-0ubuntu2
  Candidate: 3.8.2-0ubuntu2
  Version table:
 *** 3.8.2-0ubuntu2 500
        500 http://archive.ubuntu.com/ubuntu focal/main amd64 Packages
        100 /var/lib/dpkg/status

expected:
> /usr/bin/python3 -c "from sysconfig import get_path; print(get_path('purelib'))"
/usr/local/lib/python3.8/dist-packages
> DEB_PYTHON_INSTALL_LAYOUT=deb_system /usr/bin/python3 -c "from sysconfig import get_path; print(get_path('purelib'))"
/usr/lib/python3/dist-packages

what happened instead:
> /usr/bin/python3 -c "from sysconfig import get_path; print(get_path('purelib'))"
/usr/lib/python3.8/site-packages
> DEB_PYTHON_INSTALL_LAYOUT=deb_system /usr/bin/python3 -c "from sysconfig import get_path; print(get_path('purelib'))"
/usr/lib/python3.8/site-packages

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in python3.8 (Ubuntu):
status: New → Confirmed
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.