altdesktop / python-dbus-next

🚌 The next great DBus library for Python with asyncio support
https://python-dbus-next.readthedocs.io/en/latest/
MIT License
191 stars 60 forks source link

InvalidAddressError upon MessageBus().connect()? #124

Open tigerinus opened 2 years ago

tigerinus commented 2 years ago
from dbus_next.aio import MessageBus

import asyncio

loop = asyncio.get_event_loop()

async def main():
    bus = await MessageBus().connect()

loop.run_until_complete(main())

First time using this library. Tried the example code above and got

Exception has occurred: InvalidAddressError
address option did not contain a value

I double checked dbus daemon is running:

$ service --status-all
 [ + ]  acpid
 [ - ]  anacron
 [ + ]  avahi-daemon
 [ - ]  console-setup.sh
 [ + ]  cron
 [ + ]  dbus
 [ + ]  docker
 [ - ]  grub-common
 [ - ]  hwclock.sh
 [ + ]  irqbalance
 [ + ]  kerneloops
 [ - ]  keyboard-setup.sh
 [ + ]  kmod
 [ + ]  procps
 [ - ]  rsync
 [ + ]  smartmontools
 [ + ]  ssh
 [ + ]  udev
 [ - ]  uuidd

Any clue what's going on here?