Python bindings broken due to changes in GObject overrides API

Bug #1312457 reported by Robert Bruce Park
28
This bug affects 6 people
Affects Status Importance Assigned to Milestone
gexiv2
Fix Released
Critical
gexiv2 (Ubuntu)
Fix Released
Undecided
Robert Bruce Park
Trusty
Fix Released
Undecided
Robert Bruce Park

Bug Description

[Impact]

 * GExiv2 python bindings are not functional, this means that python applications trying to use GExiv2 do not work.

 * This worked in Saucy but regressed in Trusty.

 * The upload fixes the bug by updating GExiv2.py to the new GObject override API.

[Test Case]

1. Get an application that uses the python bindings to GExiv2, such as GottenGeography

2. Try to open a photo.

Expected behavior: The photo opens.

Actual behavior: the program crashes.

[Regression Potential]

Very little, the changes are confined to GExiv2.py, which is already completely broken. This change can't possibly break it any worse than it already is.

[Other Info]

I've reported the bug upstream with patch here:

https://bugzilla.gnome.org/show_bug.cgi?id=728909

Revision history for this message
Robert Bruce Park (robru) wrote :
Changed in gexiv2 (Ubuntu):
assignee: nobody → Robert Bruce Park (robru)
status: New → In Progress
description: updated
Revision history for this message
Robert Bruce Park (robru) wrote :

Here's the simplest reproducer:

$ python3
Python 3.4.0 (default, Apr 11 2014, 13:05:11)
[GCC 4.8.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from gi.repository import GExiv2
>>> m = GExiv2.Metadata('IMG_2411.JPG')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: GObject.__init__() takes exactly 0 arguments (1 given)

(__init__ is expected to take an argument, but doesn't because the overrides aren't functioning)

Changed in gexiv2 (Ubuntu):
status: In Progress → Fix Committed
Changed in gexiv2 (Ubuntu Trusty):
status: New → Fix Committed
assignee: nobody → Robert Bruce Park (robru)
Revision history for this message
Jim Nelson (yorba-jim) wrote :

I've released gexiv2 0.10.1 with Robert's patch: https://download.gnome.org/sources/gexiv2/0.10/gexiv2-0.10.1.tar.xz

Revision history for this message
Robert Bruce Park (robru) wrote :

Thanks Jim. The SRU I started is still in the UNAPPROVED queue:

https://launchpad.net/ubuntu/trusty/+queue?queue_state=1&queue_text=gexiv2

Just waiting for an SRU team member to accept it to get this fixed in Trusty.

Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Robert, or anyone else affected,

Accepted gexiv2 into trusty-proposed. The package will build now and be available at http://launchpad.net/ubuntu/+source/gexiv2/0.10.0-1ubuntu2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

tags: added: verification-needed
Revision history for this message
Robert Bruce Park (robru) wrote :

Thanks Brian! I tested this in a fresh VM today and it looks really good, fixes the issue completely. Please accept!

tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gexiv2 - 0.10.0-1ubuntu2

---------------
gexiv2 (0.10.0-1ubuntu2) trusty-proposed; urgency=low

  * debian/patches/fix-python-bindings.patch
    - updates GExiv2.py to match current GObject override API (LP: #1312457)
 -- Robert Bruce Park <email address hidden> Thu, 24 Apr 2014 15:37:23 -0700

Changed in gexiv2 (Ubuntu Trusty):
status: Fix Committed → Fix Released
Revision history for this message
Chris Halse Rogers (raof) wrote : Update Released

The verification of the Stable Release Update for gexiv2 has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regresssions.

Changed in gexiv2 (Ubuntu):
status: Fix Committed → Fix Released
Changed in gexiv2:
importance: Unknown → Critical
status: Unknown → Fix Released
Revision history for this message
Jason Moore (moorepants) wrote :

This same bug is occurring for me on yakkety. This is the package I have installed:

moorepants@garuda:~$ aptitude show gir1.2-gexiv2-0.10
Package: gir1.2-gexiv2-0.10
Version: 0.10.4-1~jensge1~yakkety3
State: installed
Automatically installed: no
Priority: extra
Section: introspection
Maintainer: Jens Georg <email address hidden>
Architecture: amd64
Uncompressed Size: 25.6 k
Conflicts: gir1.2-gexiv2-0.10, gir1.2-gexiv2-0.10:i386, gir1.2-gexiv2-0.10:i386
Replaces: gir1.2-gexiv2-0.10, gir1.2-gexiv2-0.10:i386
Description: GObject introspection data for the GExiv2 library.
 This package contains introspection data for GExiV2.

 It can be used by packages using the GIRepository format to generate dynamic bindings.

moorepants@garuda:~$ /usr/bin/ipython
Python 2.7.12+ (default, Sep 17 2016, 12:08:02)
Type "copyright", "credits" or "license" for more information.

IPython 2.4.1 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.

In [2]: from gi.repository import GExiv2
/usr/bin/ipython:1: PyGIWarning: GExiv2 was imported without specifying a version first. Use gi.require_version('GExiv2', '0.10') before import to ensure that the right version gets loaded.
  #! /usr/bin/python

In [3]: GExiv2.get_version()
Out[3]: 1004

In [4]: GExiv2.MAJOR_VERSION
Out[4]: 0

In [5]: GExiv2.MICRO_VERSION
Out[5]: 4

In [6]: GExiv2.MINOR_VERSION
Out[6]: 10

In [7]: m = GExiv2.Metadata('/home/moorepants/Pictures/2017/02/19/')
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-7-2accd458efa5> in <module>()
----> 1 m = GExiv2.Metadata('/home/moorepants/Pictures/2017/02/19/')

TypeError: GObject.__init__() takes exactly 0 arguments (1 given)

Revision history for this message
Robert Bruce Park (robru) wrote :

The package you are using is not the package that ships with yakkety. I'm not sure what package that is but you should report this failure to Jens Georg <email address hidden> as he's apparently maintaining it.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.