After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 757537 - Gnome-tweak-tool should call gi.require_version() before importing packages from gi
Gnome-tweak-tool should call gi.require_version() before importing packages f...
Status: RESOLVED FIXED
Product: gnome-tweak-tool
Classification: Applications
Component: general
3.18.x
Other All
: Normal normal
: ---
Assigned To: GNOME Tweak Tool maintainer(s)
GNOME Tweak Tool maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2015-11-03 18:21 UTC by Christian Stadelmann
Modified: 2015-11-11 18:06 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add missing gi.require_version() calls (1.75 KB, patch)
2015-11-11 17:57 UTC, Rui Matos
committed Details | Review

Description Christian Stadelmann 2015-11-03 18:21:49 UTC
When starting gnome-tweak-tool with gtk 3.18 on Fedora 23 I get these warnings:

gnome-tweak-tool.desktop[18089]: /usr/lib/python2.7/site-packages/gtweak/utils.py:31: PyGIWarning: Notify was imported without specifying a version first. Use gi.require_version('Notify', '0.7') before import to ensure that the right version gets loaded.
gnome-tweak-tool.desktop[18089]: /usr/lib/python2.7/site-packages/gtweak/egowrapper.py:22: PyGIWarning: Soup was imported without specifying a version first. Use gi.require_version('Soup', '2.4') before import to ensure that the right version gets loaded.
gnome-tweak-tool.desktop[18089]: /usr/lib/python2.7/site-packages/gtweak/egowrapper.py:22: PyGIWarning: SoupGNOME was imported without specifying a version first. Use gi.require_version('SoupGNOME', '2.4') before import to ensure that the right version gets loaded.
gnome-tweak-tool.desktop[18089]: /usr/lib/python2.7/site-packages/gtweak/tweaks/tweak_group_xkb.py:22: PyGIWarning: GnomeDesktop was imported without specifying a version first. Use gi.require_version('GnomeDesktop', '3.0') before import to ensure that the right version gets loaded.
Comment 1 Rui Matos 2015-11-11 17:57:10 UTC
Created attachment 315291 [details] [review]
Add missing gi.require_version() calls

pygobject now warns if we don't explicitly require a version before
importing. This adds the missing calls where appropriate.

For the pygobject change see
https://bugzilla.gnome.org/show_bug.cgi?id=727379 .
Comment 2 Rui Matos 2015-11-11 18:06:52 UTC
Attachment 315291 [details] pushed as 849b267 - Add missing gi.require_version() calls