lldb malfunctions due to faulty python path (ModuleNotFoundError: No module named 'lldb.embedded_interpreter')

Bug #1972855 reported by Fabio A.
44
This bug affects 9 people
Affects Status Importance Assigned to Milestone
llvm-defaults (Ubuntu)
Confirmed
Undecided
Unassigned
llvm-toolchain-14 (Ubuntu)
New
Undecided
Unassigned
llvm-toolchain-15 (Ubuntu)
New
Undecided
Unassigned

Bug Description

Starting lldb causes the following to happen:

$ lldb
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'lldb.embedded_interpreter'
(lldb)

This causes issues with, for instance, QtCreator, which stalls when trying to debug anything with lldb.

lldb -P gives the following path:

/usr/lib/local/lib/python3.10/dist-packages

However, that path doesn't exist:

$ ls -l /usr/lib/local/lib/python3.10/dist-packages
ls: cannot access '/usr/lib/local/lib/python3.10/dist-packages': No such file or directory

The package python3-lldb-14 provides this path, though:

/usr/lib/llvm-14/lib/python3.10/dist-packages/

Creating a symbolic link from /usr/lib/llvm-14/lib/python3.10/dist-packages/ to /usr/lib/local/lib/python3.10/dist-packages makes things work as expected:

$ ls -l /usr/lib/local/lib/python3.10/dist-packages && lldb
lrwxrwxrwx 1 root root 45 May 10 15:23 /usr/lib/local/lib/python3.10/dist-packages -> /usr/lib/llvm-14/lib/python3.10/dist-packages
(lldb)

Now QtCreator functions fine with lldb.

ProblemType: Bug
DistroRelease: Ubuntu 22.04
Package: lldb 1:14.0-55~exp2
ProcVersionSignature: Ubuntu 5.15.0-27.28-lowlatency 5.15.30
Uname: Linux 5.15.0-27-lowlatency x86_64
ApportVersion: 2.20.11-0ubuntu82
Architecture: amd64
CasperMD5CheckResult: unknown
CurrentDesktop: Unity:Unity7:ubuntu
Date: Tue May 10 15:18:41 2022
InstallationDate: Installed on 2015-02-26 (2630 days ago)
InstallationMedia: Ubuntu 14.10 "Utopic Unicorn" - Release amd64 (20141022.1)
SourcePackage: llvm-defaults
UpgradeStatus: Upgraded to jammy on 2022-05-02 (7 days ago)

Revision history for this message
Fabio A. (falemagn) wrote :
description: updated
summary: - lldb cannot startup due to faulty python path
+ lldb malfunctions due to faulty python path
description: updated
summary: - lldb malfunctions due to faulty python path
+ lldb malfunctions due to faulty python path (ModuleNotFoundError: No
+ module named 'lldb.embedded_interpreter')
Revision history for this message
Launchpad Janitor (janitor) wrote :

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

Changed in llvm-defaults (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.