Slimbook-Team / slimbookamdcontroller

GNU General Public License v3.0
35 stars 8 forks source link

Indicator does not start #11

Closed hachikoharuno closed 2 years ago

hachikoharuno commented 2 years ago

In autorun, this command is installed by the application itself:

python3 /usr/share/slimbookamdcontroller/src/slimbookamdcontrollerindicator.py

When executing this command from the console, no error occurs, but when autostart gets out this error:

(slimbookamdcontrollerindicator.py:1265): Gtk-CRITICAL **: 11: 00: 47.147: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

I got this error when upgrading kubuntu, when upgrading kde neon, and when installing on ubuntu 21.04 Gnome 40. Now I use arch with kde and this error came out again, despite the slimbook battery indicator working fine. The SlimbookAmdController program itself works fine, but not its indicator. Perhaps the indicator depends on the settings of the working environment that are reset during the update or are simply not configured as they are now, but my attempts to fix the error were unsuccessful.

Also when I add environment settings GDK_BACKEND = x11, the indicator appears, but the icon becomes blurry and less responsive, and the toggle menu does not scale correctly. By the way, I'm using Wayland.

slimbook commented 2 years ago

Hi @hachikoharuno, we are going to investigate it. Were you using Wayland in all distros you mentioned?,

(slimbookamdcontrollerindicator.py:1265): Gtk-CRITICAL **: 11: 00: 47.147: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Is this shown as an application crash error? If not, how did you get it?

Thanks for reporting, we didn't notice, originally, the app was made for X11, but we will try to reproduce this error to see what happens and make it work fine in wayland as it is very extended.

hachikoharuno commented 2 years ago

Hi yes, I have used wayland on all distributions I mentioned. Now the second distribution I have is ubuntu 21.10 with gnome 40 by default and wayland, everything works fine there (so I believe that gtk is not configured somewhere, although now I have all kinds of xdg portal installed). I got the error by specifying the launch of the application in the console. Here is the content of the autostart file that kde generates through the GUI, however specifying startup parameters manually is not a problem in ubuntu either: [Desktop Entry] Comment [ru_RU] = Slimbook AMD Contoller's autostart executable Comment = Slimbook AMD Contoller's autostart executable Comment [es_ES] = Arranque de autoinicio de Slimbook AMD Controller Exec = python3 /usr/share/slimbookamdcontroller/src/slimbookamdcontrollerindicator.py GenericName [ru_RU] = GenericName = Hidden = false MimeType = Name [ru_RU] = Slimbook Amd Controller Autostart Name = Slimbook Amd Controller Autostart Name [es_ES] = slimbookamdcontroller-autostart.desktop NoDisplay = false Path = StartupNotify = true Terminal = true TerminalOptions = Type = Application X-DBUS-ServiceName = X-DBUS-StartupType = none X-GNOME-Autostart-Delay = 0 X-GNOME-Autostart-enabled = true X-KDE-SubstituteUID = false X-KDE-Username =

hachikoharuno commented 2 years ago

I also forgot to mention that if I execute python3 /usr/share/slimbookamdcontroller/src/slimbookamdcontrollerindicator.py directly from the terminal, no error occurs.

slimbook commented 2 years ago

Thank you! I will make sure to check KDE.

I also forgot to mention that if I execute python3 /usr/share/slimbookamdcontroller/src/slimbookamdcontrollerindicator.py directly from the terminal, no error occurs.

You did! By the way, I understand, it's difficult to debug, just logfiles are useful sometimes

hachikoharuno commented 2 years ago

No, the problem is not that the indicator does not work at all, but that it does not work in autostart, it is not very convenient to manually launch it from the terminal every time. But if you put the launch in the terminal in the autostart file, then you get the above error.

slimbook commented 2 years ago

it is not very convenient to manually launch it from the terminal every time

Of course not, I will try to update the aur package tomorrow, current launchpad version is 0.3.7. I have not been able to find the problem neither in Ubuntu 21.10 nor in kubuntu or KDE Neon, (at least with last version), we have recently switched the indicator library to ayatana-appindicator, I'll make some tests and update as soon as I can ;)

hachikoharuno commented 2 years ago

There are no problems in standard versions of distributions. The problem arose when I updated the desktop enviroment bypassing the standard repositories. It's just that there are no DE settings presets in arch linux, so I thought that the program depended on some specific DE settings. On kde neon, the indicator stopped working normally after installing these components: bubblewrap curl icoutils vulkan-tools libvulkan1 libvulkan1: i386 wget zenity zstd cabextract. They were installed from the ubuntu repositories fresher than kde neon (yes, I know what it is stupid to do, so I left for arch). In kubuntu I then updated kde plasma bypassing the standard repositories and in ubuntu gnome too. Therefore, in the standard versions, I think there should be no problems. I looked through the logs (/ var / log /) and found nothing suitable there.

In any case, thank you very much for paying attention to my problem, I really like your software.

PS: On clean ubuntu 21.10(On Arch linux too) the / etc / sudoers file was also not changed when installing slimbookamdcontroller, I changed it manually to give ryzenadj permissions. (This is not a problem for me now, but I think you should know)

slimbook commented 2 years ago

I changed it manually to give ryzenadj permissions. (This is not a problem for me now, but I think you should know)

Okey (an ancient bug), thank you! I will check it, updating should be enough, as now uses policykit :)

Edwrom commented 2 years ago

It was working fine for several months that I installed it using slimbook ppa, on elemtary os (ubuntu 20.04) and now with the latest slimbook update, the program doesn't start. /usr/share/slimbookamdcontroller/src Traceback (most recent call last): File "/usr/bin/slimbookamdcontroller", line 35, in <module> from slimbookamdcontroller import SlimbookAMD File "/usr/share/slimbookamdcontroller/src/slimbookamdcontroller.py", line 44, in <module> config.read(CONFIG_FILE) File "/usr/lib/python3.8/configparser.py", line 697, in read self._read(fp, filename) File "/usr/lib/python3.8/configparser.py", line 1113, in _read raise e configparser.ParsingError: Source contains parsing errors: '/home/user/.config/slimbookamdcontroller/slimbookamdcontroller.conf' [line 74]: '000-8000-8000/11000-11000-15000/25000-30000-35000/ 15 w\n'

MarSlimbook commented 2 years ago

Hi, could you share your configuration file? ('/home/user/.config/slimbookamdcontroller/slimbookamdcontroller.conf'); I need to check if there is an error in your local values. Thanks!