Page 1 of 1

[Fedora 35] gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Posted: February 9th, 2022, 1:57 pm
by Conz
I noticed my SABnzbd is giving a gtk error every second and I cannot really figure out why this is.
It seems to be trying to create some sort of widget for X from what I understand after some google searching, but there is no X running.
This machine does have some minimal X installed but it is running in multi-user (Systemd's runlevel 3)
OS is Fedora 35

SABNZBpy.172799 Gtk-CRITICAL ** 19:55:36.915 gtk_widget_get_scale_factor. assertion 'GTK_IS_WIDGET (widget)' failed
(I had to mangle this error a little due to the forum's 'can't post links' thing)

I noticed the error on 3.4.2 and it is still present on 3.5.0. Ran a pip update on the requirements and it did update a package but that made no difference.
I feel like some Fedora 35 update might be at the root cause some time over the last month or so, I often run updates and SAB gets launched into the background in a tmux session so I don't always look at what it's doing.

Re: [Fedora 35] gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Posted: February 10th, 2022, 5:17 am
by jcfp
This is a harmless yet annoying gtk error related to the statusbar icon. If you want to get rid of it, disable the tray icon by unchecking the win_menu setting in config -> special.

Re: [Fedora 35] gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Posted: February 10th, 2022, 5:46 am
by Conz
jcfp wrote: February 10th, 2022, 5:17 am This is a harmless yet annoying gtk error related to the statusbar icon. If you want to get rid of it, disable the tray icon by unchecking the win_menu setting in config -> special.
Gold star, that got rid of the error ;)
I figured it was harmless other than wasted cpu cycles and the ability to spot any actual errors.
Bit weird that it just randomly started giving those errors though.

Re: [Fedora 35] gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Posted: February 10th, 2022, 9:50 am
by jcfp
Conz wrote: February 10th, 2022, 5:46 amBit weird that it just randomly started giving those errors though.
The assertion mentioned in the error in somewhere in Gtk/gdk code, so it could well have been an OS update to those libs that started it.

Re: [Fedora 35] gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Posted: November 24th, 2022, 1:15 pm
by Conz
Little update considering this is the top google result for this error.
Either Fedora 37 or SabNZBD 3.7 caused this change but the setting is now 'tray_icon' instead of 'win_menu' in the same location; config -> special.

Re: [Fedora 35] gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Posted: November 24th, 2022, 2:14 pm
by safihre
Indeed the setting was renamed but due to the limited use of people actively disabling it, no conversion was applied from the old setting.