isamert / scli

a simple terminal user interface for signal messenger (using signal-cli)
GNU General Public License v3.0
432 stars 40 forks source link

Dbus error with no display #200

Closed pem-imre closed 1 year ago

pem-imre commented 1 year ago

On my WSL2 Ubuntu box, with scli 0.7.1 and signal-cli 0.10.11, I get this message whenever I try to send a message:

Failed to open connection to "session" message bus: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11"

I see old messages and contacts that were pulled with signal-cli, but can't interact with them.

My environment does not have X11 or a GUI, just command line. Tried setting the DISPLAY env variable to 0.0, but it did not solve the issue, just produced a different error message from dbus-launch: "X11 initialization failed." Is X11 required?

exquo commented 1 year ago

X11 shouldn't be necessary, but DBus can be finicky on non-standard setups, and WSL certainly counts as one of them.

I don't have a WSL system to try this on, but here is a discussion that might be helpful: https://www.reddit.com/r/bashonubuntuonwindows/comments/9l46br/asking_wsl_ubuntu_1804_dbus_fix_updated/

This is an issue of DBus on WSL, not specific to scli or signal-cli.

pem-imre commented 1 year ago

Thank you for the clarification! I happen to have a raspberry pi server on my network that has no X either. Let me test scli on that too before closing this.

pem-imre commented 1 year ago

Just tested on a raspberry PI without X11, and no errors. So it is really a DBus anomaly specific to WSL2.