dbus-python
Python bindings for libdbus
What it is and what it does
dbus-python is the original Python binding for D-Bus, the reference implementation of the D-Bus protocol used for inter-process communication on Linux systems. It allows Python programs to call methods on, and receive signals from, system services and other applications connected to the D-Bus message bus.
The package wraps libdbus directly and requires careful main-loop integration; it does not follow a strict "refuse to guess" principle and has known limitations with multi-threaded code. The description itself lists several alternative bindings (dasbus, dbussy, dbus-next, dbus-fast, jeepney) that may better suit modern use cases, particularly if you need asyncio support or higher-level abstractions.
Use it for:
- Integrate Python applications with systemd services or other system daemons via D-Bus method calls
- Monitor system events (power state, network changes, device hotplug) by subscribing to D-Bus signals
- Build desktop applications that need to interact with GNOME, KDE, or other D-Bus-using desktop environments
- Expose Python services on the D-Bus message bus for other applications to call
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides Python bindings to libdbus, allowing Python programs to communicate over the D-Bus message bus protocol used by Linux desktop and system services.
Yes, but with conditions. Install if you need to integrate with existing D-Bus services on a Linux system and are comfortable with the high install friction (compiled dependencies) and aging codebase. If you are starting a new project, consider the alternatives listed in the package documentation—particularly dbus-next or jeepney for asyncio support, or dasbus for a higher-level interface. No known security vulnerabilities.
Install
dbus-python on PyPI
pip
pip install dbus-pythonuv
uv add dbus-pythonpoetry
poetry add dbus-pythonInstalling dbus-python
Before you install
High install friction due to compiled C dependencies on libdbus development headers. Package is aging (519 days since last release) with inactive development status, though it remains the original reference binding and receives occasional maintenance.
License in practice
Licensed under MIT (Expat), a permissive license with no restrictions on commercial or private use, modification, or redistribution.
Quickstart
import dbus
bus = dbus.SystemBus()
object_path = bus.get_object('org.freedesktop.DBus', '/org/freedesktop/DBus')
interface = dbus.Interface(object_path, 'org.freedesktop.DBus')
Requires libdbus development headers and C compiler to build; D-Bus daemon must be running on the system.
Verify before relying
- Whether the package's known limitations with multi-threaded use and main-loop selection affect your specific use case
- Current state of the GitLab repository and whether maintenance is truly inactive or episodic
Package facts
| License | Expat (MIT/X11) (permissive) |
| Python support | supports the current Python release (>=3.7) |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | aging — 519 days since the last release |
| First released | |
| Downloads | 254,565/month — #8,492 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: dbus-python-1.4.0.tar.gz
Keywords: dbus, D-Bus
Tags
More Object Brokering packages
Py4J enables Python programs to dynamically…
permissive · top 1,000 on PyPI
celeryCelery is a distributed task queue that lets…
permissive · top 1,000 on PyPI
jsonconversionConverts arbitrary Python objects to JSON…
permissive · top 5,000 on PyPI
autobahnAutobahn provides WebSocket and WAMP (Web…
permissive · top 5,000 on PyPI
celery-redbeatRedBeat is a Celery Beat scheduler that…
permissive · top 5,000 on PyPI
Pyro5Pyro5 enables remote method calls on Python…
permissive · top 15,000 on PyPI
dbus-fastdbus-fast is a Python library for D-Bus…
permissive · top 5,000 on PyPI
jeepneyJeepney is a pure Python implementation of…
permissive · top 1,000 on PyPI
sdbusPython library for D-Bus communication with…
copyleft · top 15,000 on PyPI
dbus-nextA pure-Python DBus library for Linux desktop…
permissive · top 15,000 on PyPI
notify2notify2 creates and displays desktop…
permissive · top 15,000 on PyPI
PyGObjectPyGObject provides Python bindings for…
copyleft · top 15,000 on PyPI
dlinfoProvides Python access to libc's dlinfo…
permissive · top 5,000 on PyPI
python-xlibA pure-Python X11 client library that…
copyleft · top 5,000 on PyPI
spidevProvides Python bindings to interact with SPI…
permissive · top 15,000 on PyPI
pyobjc-framework-libxpcProvides Python bindings to the macOS XPC…
permissive · top 15,000 on PyPI