webketje/tuxedo-backlight-control

program cannot read $DISPLAY

xevilstar opened this issue · 9 comments

/usr/share/tuxedo-backlight-control/ui.py --help
Traceback (most recent call last):
File "/usr/share/tuxedo-backlight-control/ui.py", line 358, in
init()
File "/usr/share/tuxedo-backlight-control/ui.py", line 352, in init
root = tk.Tk()
File "/usr/lib/python3.10/tkinter/init.py", line 2299, in init
self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: no display name and no $DISPLAY environment variable

echo $DISPLAY
:0

I have the same issue on Ubuntu 20.04

Traceback (most recent call last):
  File "/usr/share/tuxedo-backlight-control/ui.py", line 360, in <module>
    init()
  File "/usr/share/tuxedo-backlight-control/ui.py", line 354, in init
    root = tk.Tk()
  File "/usr/lib/python3.8/tkinter/__init__.py", line 2270, in __init__
    self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: no display name and no $DISPLAY environment variable

@cydia2020 please read through #11 and especially see if the suggestion in this comment works for you: #11 (comment)..
I should really add a troubleshooting guide in the README.md and create a GH issue template

sorry but rebooting doesn't help

sorry but rebooting doesn't help

Yup, same situation here, rebooting doesn't help.

strangely enough .....

cat /sys/devices/platform/tuxedo_keyboard/input/input34/capabilities/led
0

@xevilstar your persistence is admirable, I'm sorry I cannot help.
The only thing I can do is look around for clues, for example at Tuxedo keyboard a lot of issues have been reported/ PR's opened over the last year:
https://github.com/tuxedocomputers/tuxedo-keyboard/issues
https://github.com/tuxedocomputers/tuxedo-keyboard/pulls

For example, this PR tuxedocomputers/tuxedo-keyboard#101 mentions incompatibility with Linux Kernel 5.13+ . FWIW I'm still on Linux kernel 5.4 (last time I tried to upgrade there were too many issues)

Regarding the path you inspected, mine is under cat /sys/devices/platform/tuxedo_keyboard/input/input18 and my "led" file also has a 0 as value, so that will not be the issue.

I don't have the time nor resources to re-install locally or test extensively on VMs.

the project will die if you don't update

Feel free to fork and propose a pull request for addressing any issues I do not have the time, expertise or resources for. Please remain civil and constructive.

If I had the ability to code something out I would, I am just testing ....