GNOME Bugzilla – Bug 670507
gobject-introspection: g_log_set_handler is not available.
Last modified: 2018-02-08 12:13:59 UTC
Currently g_log_set_handler is not available from GLib-2.0.typelib. I'm attaching the patch.
Created attachment 208089 [details] [review] Patch for gir/glib-2.0.c Attached the patch to fix the gir annotation.
Review of attachment 208089 [details] [review]: the scope is not really async, here: the user_data will be leaked, since there's no actual way to remove or unset a log handler. using async is incorrect, and may lead to bugs in the language bindings. this kind of closures do not have a scope tag yet; see bug 556489.
It will always leak, but it might make sense to add a (scope forever) or so which would have almost the same behavior as async.
Bug 556489 has been closed and there is a binding for g_log_remove_handler, so can this be fixed now? What I want to do is get a python stack traceback when something internal to glib/gobject causes assertion warnings. Will that work or would the traceback not be able to traverse the python/C interface?
Since g_log_remove_handler does not have a destroy argument, this problem can not be fixed until glib releases a new function? I guess the scope is notified.
[Mass-moving gobject-introspection tickets to its own Bugzilla product - see bug 708029. Mass-filter your bugmail for this message: introspection20150207 ]
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gobject-introspection/issues/64.