Re: [wxPython-users] Re: GTK error messages

Michael Eager <[email protected]> Tue, 29 Dec 2020 08:54:48 -0800
Newsgroups gmane.comp.lib.wxwindows.general,gmane.comp.python.wxpython
Message-ID <[email protected]>
On 12/28/20 6:39 PM, Scott Talbert wrote:
> On Mon, 28 Dec 2020, Michael Eager wrote:
> 
>> I'm running a wxPython program using a wx.ScrolledWindow.  I'm getting 
>> a lot of the following console messages:
>>
>> (main.py:1170792): Gtk-CRITICAL **: 08:59:46.366: 
>> gtk_box_gadget_distribute: assertion 'size >= 0' failed in GtkScrollbar
>>
>> I'm guessing that there is something in the way that the 
>> ScrolledWindow widget is initialized that is incorrect or incomplete.
>>
>> Can anyone suggest how to debug this?
>>
>> What's the best way to track back from a GTK error to the wxWidgets 
>> code triggering the error?
>>
>> wxWidgets Library Version 3.1.5,  Compiled Dec 17, 2020 (using pip3).
>> Runtime version 3.22.  Compile-time GTK 3.22.30.
> 
> Unfortunately, GTK is rather noisy with its warnings and this doesn't 
> *necessarily* indicate that there's a bug somewhere (although there 
> could be).  Do you see any problems in your application?
> 
> You can make a GTK program abort on the first warning using a special 
> command line option, --g-fatal-warnings.  With this you can get a stack 
> trace with gdb when the warning occurs.  Doing it with Python is a 
> little tricky, but here's how you can do it:
> 
> $ gdb python3
> 
> ...
> 
> (gdb) run <your program>.py --g-fatal-warnings
> 
> Then you should be able to get a stack trace, debug, etc. when one of 
> those warnings occurs.

Thanks.  I'll give that a try.

Would it help to build a local debug version of wxWidgets?


-- 
Michael Eager

-- 
Please read http://www.wxwidgets.org/support/mlhowto.htm before posting.

To unsubscribe, send email to [email protected]
or visit http://groups.google.com/group/wx-users
--- 
You received this message because you are subscribed to the Google Groups "wx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/wx-users/158745dc-d7cf-0e7f-eb4f-ea4d544af9b8%40eagercon.com.