Sugar Labs

Port GObject based methods and constants references to GLib in Infoslicer-activity

Thousands of PyGIDeprecationWarning occur in shell.log and activity logs when using PyGObject development releases, because of our use of GObject instead of GLib for certain methods. These should be changed. Examples include;

  • GObject.idle_add to GLib.idle_add,
  • GObject.timeout_add to GLib.timeout_add,
  • GObject.source_remove to GLib.source_remove,
  • GObject.PRIORITY_HIGH to GLib.PRIORITY_HIGH, Also a few other warnings occur within GObject alone;
  • GObject.property is to change to GObject.Property,
  • GObject.PARAM_* is to change to GObject.ParamFlags.*,

Also positional arguments with the GObject constructor have been deprecated, we must use keywords instead, reference: https://wiki.gnome.org/PyGObject/InitializerDeprecations

To understand the task better, refer to items in the Done Section.

For background information check here.

Task tags

  • python
  • gobject
  • glib

Students who completed this task

Alejandro Garcia

Task type

  • code Code
close

2018