ModuleNotFoundError: No module named 'gattlib'

Bug #1891759 reported by Etienne Membrives on 2020-08-15
This bug affects 1 person
Affects Status Importance Assigned to Milestone
pybluez (Debian)
pybluez (Ubuntu)

Bug Description

I installed python3-bluez on Ubuntu 20.04:
 $> sudo apt install python3-bluez

However, using this package in python3 leads to an error:
 $> python3
 Python 3.8.2 (default, Jul 16 2020, 14:00:26)
 [GCC 9.3.0] on linux
 Type "help", "copyright", "credits" or "license" for more information.
 >>> import bluetooth.ble
 Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
   File "/usr/lib/python3/dist-packages/bluetooth/", line 1, in <module>
     from gattlib import *
 ModuleNotFoundError: No module named 'gattlib'

I tried searching for package with "gattlib" in its name, but apt does not find anything.

ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: python3-bluez 0.22+really0.22-1build2
ProcVersionSignature: Ubuntu 5.4.0-42.46-generic 5.4.44
Uname: Linux 5.4.0-42-generic x86_64
NonfreeKernelModules: nvidia_modeset nvidia
ApportVersion: 2.20.11-0ubuntu27.6
Architecture: amd64
CasperMD5CheckResult: skip
CurrentDesktop: ubuntu:GNOME
Date: Sat Aug 15 16:54:34 2020
InstallationDate: Installed on 2019-05-11 (462 days ago)
InstallationMedia: Ubuntu 19.04 "Disco Dingo" - Release amd64 (20190416)
SourcePackage: pybluez
UpgradeStatus: Upgraded to focal on 2020-05-08 (98 days ago)

Hans Joachim Desserud (hjd) wrote :

Thanks for reporting.

I get the same error message when attempting to import ble with python3-bluez 0.23-1ubuntu1 on Ubuntu Groovy. Doing some more research, I found the corresponding Debian bug report, see the attached bug watch.

Changed in pybluez (Ubuntu):
status: New → Confirmed
tags: added: groovy
Changed in pybluez (Debian):
status: Unknown → New
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.