Creating a GtkShortcutsWindow triggers a warning about GtkContainer:child being deprecated
Steps to reproduce
Enable warnings with export G_ENABLE_DIAGNOSTIC=1
and run this simple Python program:
#!/usr/bin/python3
import gi
gi.require_version("Gtk", "3.0")
from gi.repository import Gtk # noqa: E402
win = Gtk.ShortcutsWindow(title="Example")
win.show_all()
Gtk.main()
Current behavior
/usr/lib/python3/dist-packages/gi/overrides/__init__.py:319: Warning: The property GtkContainer:child is deprecated and shouldn't be used anymore. It will be removed in a future version.
Expected outcome
No warning.
Version information
GTK 3.24.20 from Ubuntu 20.04.1 PyGObject 3.36.0
Additional information
Issue #2081 (closed) describes a similar issue. Following the same process for debugging as outlined in that issue provides the traceback below (only showing top 10 calls). I do not have enough experience to interpret what this means, but thought it might be useful to someone who does.
(junk5.py:3539): GLib-GObject-WARNING **: 23:43:16.688: The property GtkContainer:child is deprecated and shouldn't be used anymore. It will be removed in a future version.
Program received signal SIGTRAP, Trace/breakpoint trap.
0x00007ffff753b0d5 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
(gdb) bt
#0 0x00007ffff753b0d5 in () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#1 0x00007ffff753c3b9 in g_logv () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2 0x00007ffff753c583 in g_log () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3 0x00007ffff749d56b in () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#4 0x00007ffff749f378 in g_object_new_valist () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#5 0x00007ffff749f6cd in g_object_new () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#6 0x00007ffff5bbb88f in () at /lib/x86_64-linux-gnu/libgtk-3.so.0
#7 0x00007ffff74be16d in g_type_create_instance () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#8 0x00007ffff749d34d in () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#9 0x00007ffff749eafb in g_object_new_with_properties () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#10 0x00007ffff7638e0c in pygobject_object_new_with_properties
...