Mixes static and GI library bindings

Bug #829186 reported by Martin Pitt
60
This bug affects 7 people
Affects Status Importance Assigned to Milestone
Ubuntu One Client
Fix Released
Medium
Martin Pitt
Ubuntu One Control Panel
Fix Released
Medium
Martin Pitt
Ubuntu Single Sign On Client
Fix Released
Medium
Martin Pitt
gwibber (Ubuntu)
Fix Released
High
Ken VanDine
jockey (Ubuntu)
Fix Released
Undecided
Martin Pitt
oneconf (Ubuntu)
Fix Released
High
Unassigned
software-center (Ubuntu)
Fix Released
Undecided
Martin Pitt
ubiquity (Ubuntu)
Fix Released
High
Martin Pitt
ubuntu-sso-client (Ubuntu)
Fix Released
High
Martin Pitt
ubuntuone-client (Ubuntu)
Fix Released
High
Martin Pitt
ubuntuone-control-panel (Ubuntu)
Fix Released
High
Martin Pitt
update-manager (Ubuntu)
Fix Released
High
Unassigned
usb-creator (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

This is a tracking bug for fixing programs which will crash with a newer pygobject >= 2.90. This is now absolutely zero tolerant against importing both the static and the GI version of a particular library. This was mostly the case with 2.28 as well, but did work in some cases (like "import gobject; from gi.repository import Gtk", in particular for "glib" and "gobject"). These now cause errors as well.

See bug 828751 for some more information for this.

$ ubuntuone-control-panel-gtk
Traceback (most recent call last):
  File "/usr/bin/ubuntuone-control-panel-gtk", line 33, in <module>
    from ubuntuone.controlpanel.gui.gtk import main
  File "/usr/lib/python2.7/dist-packages/ubuntuone-control-panel/ubuntuone/controlpanel/gui/gtk/__init__.py", line 28, in <module>
    from ubuntuone.controlpanel.gui.gtk.gui import main
  File "/usr/lib/python2.7/dist-packages/ubuntuone-control-panel/ubuntuone/controlpanel/gui/gtk/gui.py", line 39, in <module>
    from gi.repository import GLib
  File "/usr/lib/python2.7/dist-packages/gi/__init__.py", line 23, in <module>
    from ._gi import _API, Repository
ImportError: could not import gobject (error was: ImportError('When using gi.repository you must not import static modules like "gobject". Please change all occurrences of "import gobject" to "from gi.repository import GObject".',))

Related branches

Revision history for this message
Martin Pitt (pitti) wrote :

$ /usr/share/oneconf/oneconf-service
Traceback (most recent call last):
  File "/usr/share/oneconf/oneconf-service", line 102, in <module>
    myservice = DbusHostsService(loop)
  File "/usr/share/oneconf/oneconf/dbusconnect.py", line 55, in __init__
    from oneconf.hosts import Hosts, HostError
  File "/usr/share/oneconf/oneconf/hosts.py", line 26, in <module>
    from gi.repository import Gio
  File "/usr/lib/python2.7/dist-packages/gi/__init__.py", line 23, in <module>
    from ._gi import _API, Repository
ImportError: could not import gobject (error was: ImportError('When using gi.repository you must not import static modules like "gobject". Please change all occurrences of "import gobject" to "from gi.repository import GObject".',))

Changed in ubuntuone-control-panel (Ubuntu):
importance: Undecided → High
status: New → Triaged
Changed in oneconf (Ubuntu):
importance: Undecided → High
status: New → Triaged
description: updated
Revision history for this message
Martin Pitt (pitti) wrote :

This is a curious case where the old pygobject 2.28 actually silently hid a bug in the code:

$ update-manager
Traceback (most recent call last):
  File "/usr/bin/update-manager", line 109, in <module>
    app.main(options)
  File "/usr/lib/python2.7/dist-packages/UpdateManager/UpdateManager.py", line 1211, in main
    self.fillstore()
  File "/usr/lib/python2.7/dist-packages/UpdateManager/UpdateManager.py", line 1066, in fillstore
    self.update_count()
  File "/usr/lib/python2.7/dist-packages/UpdateManager/UpdateManager.py", line 679, in update_count
    GLib.timeout_add_seconds(GLib.PRIORITY_DEFAULT, 10, self.update_last_updated_text, None)
TypeError: second argument not callable

Changed in update-manager (Ubuntu):
importance: Undecided → High
status: New → Triaged
Revision history for this message
Martin Pitt (pitti) wrote :

Fixed in update-manager bzr.

Changed in update-manager (Ubuntu):
status: Triaged → Fix Committed
Revision history for this message
Martin Pitt (pitti) wrote :

I checked/fixed most other packages that use GI already, but ubiquity is a very important one which I haven't checked yet. It might work, but adding this task as a reminder for me.

Changed in ubiquity (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → High
status: New → Incomplete
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package oneconf - 0.2.5

---------------
oneconf (0.2.5) oneiric; urgency=low

  * oneconf/hosts.py: Don't use gi.repository.Gio, as we are using static
    bindings here still (gtk, gobject, etc.); call "gsettings" instead. This
    can be put back once the GUI etc. gets ported to GI, and we switch to the
    ported software-center. (LP: #829186)
 -- Martin Pitt <email address hidden> Fri, 19 Aug 2011 07:21:32 +0200

Changed in oneconf (Ubuntu):
status: Triaged → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

I have the GTK UI side of the u1-control-panel fixed in lp:~pitti/ubuntuone-control-panel/mix-static-gi, but bin/ubuntuone-control-panel-backend is harder: it uses

   from gi.repository import Soup, SoupGNOME

which includes GObject. I'm not sure whether this could just be changed to use httplib instead, needs input from the U1 team , I'm afraid.

Revision history for this message
Martin Pitt (pitti) wrote :

I did a code grep of ubiquity, and it seems alright. ubiquity/frontend/noninteractive.py imports "gobject" and could be moved to gi.repository.GObject, but as it doesn't use any GI bindings, it ought to work.

I'll test this on a live system once we get a daily build with the new ubiquity.

Revision history for this message
Michael Vogt (mvo) wrote :

The software-center gtk2 version still needs the old "gmenu". While the code is there to use the new gmenu there is also the old gtk2 interfaces that will crash if it uses the new gmenu.

Revision history for this message
Martin Pitt (pitti) wrote :

software-center-gtk3 works fine with new pygobject, but the gtk2 variant crashes now:

$ software-center
Traceback (most recent call last):
  File "/usr/bin/software-center", line 136, in <module>
    from softwarecenter.ui.gtk.app import SoftwareCenterApp
  File "/usr/share/software-center/softwarecenter/ui/gtk/app.py", line 73, in <module>
    from installedpane import InstalledPane
  File "/usr/share/software-center/softwarecenter/ui/gtk/installedpane.py", line 34, in <module>
    from softwarepane import SoftwarePane
  File "/usr/share/software-center/softwarecenter/ui/gtk/softwarepane.py", line 58, in <module>
    from appdetailsview_gtk import AppDetailsViewGtk as AppDetailsView
  File "/usr/share/software-center/softwarecenter/ui/gtk/appdetailsview_gtk.py", line 45, in <module>
    from softwarecenter.backend.weblive import get_weblive_backend
  File "/usr/share/software-center/softwarecenter/backend/weblive.py", line 25, in <module>
    from gi.repository import GObject
  File "/usr/lib/python2.7/dist-packages/gi/__init__.py", line 23, in <module>
    from ._gi import _API, Repository
ImportError: could not import gobject (error was: ImportError('When using gi.repository you must not import static modules like "gobject". Please change all occurrences of "import gobject" to "from gi.repository import GObject".',))

Martin Pitt (pitti)
Changed in software-center (Ubuntu):
status: New → Fix Committed
assignee: nobody → Martin Pitt (pitti)
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package update-manager - 1:0.152.15

---------------
update-manager (1:0.152.15) oneiric; urgency=low

  [ Brian Murray ]
  * DistUpgrade/DistUpgradeApport.py:
    - properly add the tag 'dist-upgrade' to the bug report

  [ Michael Vogt ]
  * UpdateManager/backend/InstallBackendAptdaemon.py:
    - fix incorrect initialization
  * fix GLib.timeout_add_seconds() with the new GIR (LP: #829186)
  * call software-properties-gtk without gksu, that is no longer
    needed
 -- Michael Vogt <email address hidden> Fri, 19 Aug 2011 12:15:35 +0200

Changed in update-manager (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package software-center - 4.1.17

---------------
software-center (4.1.17) oneiric; urgency=low

  [ Matthew McGowan ]
  * lp:~mmcg069/software-center/gtk3fix:
    - description.py, do not connect to the viewport size-allocate signal,
      i think this should prevent the wierd spazz out when resize evetns
      occur

  [ Michael Vogt ]
  * softwarecenter/utils.py:
    - really remove old gmenusearcher code that uses the static gmenu
      bindings (LP: #828535)
  * softwarecenter/ui/{gtk,gtk3}/gmenusearch.py:
    - split gmenusearch into gtk2 (static bindings) and gtk3 (gi bindings)
    - update usage
  * softwarecenter/db/history_impl/apthistory.py:
    - add conditional use of gio.File() vs Gio.File.new_for_path()
  * softwarecenter/utils.py, softwarecenter/backend/reviews.py:
    - fixes in subtle API changes for Gio vs gio
  * softwarecenter/ui/gtk3/widgets/description.py:
    - prepare for upcomming Gdk pygi changes in 2.90.x
  * debian/control:
    - add python-gmenu back to the dependencies, the dynamic bindings
      can not be used with the gtk2 version os software-center
  * utils/piston-helpers/piston_get_useful_votes_helper.py,
    utils/piston-helpers/piston_get_reviews_helper.py:
    - fix exception type now that json is used (instead of simplejson)
      LP: #828324

  [ Kiwinote ]
  * data/ui/gtk3/css/softwarecenter.css:
    - theme GtkViewports not to have a padding or a border - looks quite nice
      around the banners now
  * many:
    - transition from a status bar to internal status labels (LP: #445558)
  * softwarecenter/ui/gtk3/session/viewmanager.py:
    - show/hide search entry when needed (LP: #828790)
  * softwarecenter/ui/gtk3/views/appdetailsview_gtk.py:
    - use a Gtk.IconSize rather than an int for Gtk.Image.new_from_icon_name
  * softwarecenter/ui/gtk3/widgets/buttons.py:
    - ellipsize category text in tile to avoid warnings
    - show channel selector on button-press-event instead of
      button-release-event for consistent menu behaviour (LP: #828317)

  [ Martin Pitt ]
  * Fix some more places which need to conditionally import gobject or
    GObject. (LP: #829186)
 -- Michael Vogt <email address hidden> Fri, 19 Aug 2011 11:59:02 +0200

Changed in software-center (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Natalia Bidart (nataliabidart) wrote : Re: [Bug 829186] Re: Mixes static and GI library bindings

On 08/19/2011 02:32 AM, Martin Pitt wrote:
> I have the GTK UI side of the u1-control-panel fixed in lp:~pitti
> /ubuntuone-control-panel/mix-static-gi, but bin/ubuntuone-control-panel-
> backend is harder: it uses
>
> from gi.repository import Soup, SoupGNOME
>
> which includes GObject. I'm not sure whether this could just be changed
> to use httplib instead, needs input from the U1 team , I'm afraid.

Like we agreed on IRC, Martin and me will be reviewing this next Wed.
Until then, Martin will analyze how easy/difficult would be to migrate
the controlpanel to GTK+3, which will solve this issue.

Thanks!

Evan (ev)
Changed in ubiquity (Ubuntu):
status: Incomplete → Fix Committed
Changed in jockey (Ubuntu):
status: New → Confirmed
Revision history for this message
Martin Pitt (pitti) wrote :

I already fixed jockey upstream.

Changed in jockey (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
status: Confirmed → Fix Committed
Revision history for this message
Martin Pitt (pitti) wrote :

To whoever added the usb-creator task: I already fixed this in oneiric in

usb-creator (0.2.31.2) oneiric; urgency=low

  * usbcreator/frontends/gtk/frontend.py: Move from static gobject to GI
    GObject module, to be compatible to upcoming pygobject 3.0.

 -- Martin Pitt <email address hidden> Wed, 17 Aug 2011 08:22:11 +0200

If you still get a crash with this version and the new pygobject, please give a reproducer and/or stack trace here. Thanks!

Changed in usb-creator (Ubuntu):
status: New → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package jockey - 0.9.4-0ubuntu1

---------------
jockey (0.9.4-0ubuntu1) oneiric; urgency=low

  * New upstream bug fix release:
    - oslib.py: Do not encourage to report package installation failure as
      SystemError, it will appear as a backend crash
    - jockey-gtk: Fix message_type argument to Gtk.MessageBox constructor
    - jockey/ui.py: For invalid combinations of LC_MESSAGES and LC_CTYPE, force
      stdout/stderr encoding to UTF-8 instead of C. (LP: #760883)
    - Fix GLib and GObject imports to be compatible with the future pygobject
      3.0. (LP: #829186)
    - jockey/detection.py, _driverid_to_handler(): In the case that there are
      multiple matching custom handlers for a DriverID, also check that their
      "package" attribute matches.
    - tests/run: Also support specifying individual test method names
  * Add debian/testpkgs/: Scripts and equivs control files for dummy
    driver packages which are convenient for testing.
  * debian/rules: Call debian/testpkgs/clean to ensure that we don't ship
    build stuff there.
  * data/handlers/{fglrx,nvidia}.py: Prevent crash if
    get_alternative_by_name() returns nothing.
  * jockey/oslib.py, {install,remove}_package(): Capture apt's stdout/err into
    the log file, to get proper error messages when packages fail to install.
    (LP: #552300).
  * jockey/oslib.py, install_package(): Avoid raising a SystemError when a
    package fails to install in apt, as this will appear as a crash in Jockey.
    Just point out the error in the log file instead. (LP: #804709)
  * tests/oslib.py: Update test cases for above change.
  * tests/oslib.py: Fix apt initialization to work with current apt versions.
  * data/handlers/{fglrx,nvidia}.py: Also show the -updates variants of the
    drivers, which will be updated to newer upstream versions after the
    Ubuntu release. (UbuntuSpec:desktop-o-xorg-stakeholders-request)
 -- Martin Pitt <email address hidden> Mon, 22 Aug 2011 12:08:02 +0200

Changed in jockey (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

python-ubuntuone-client needs to be taught to get along with either, I already have a patch for it. Will submit upstream once I/we get the control-panel port done.

Changed in ubuntuone-client (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → High
status: New → Triaged
Revision history for this message
Martin Pitt (pitti) wrote :

While working on the UbuntuOne packages, I noticed that ubuntu-sso-client needs to be conditionalized, too:

  File "/usr/lib/python2.7/dist-packages/ubuntu-sso-client/ubuntu_sso/utils/txsecrets.py", line 24, in <module>
    import gobject

Changed in ubuntu-sso-client (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → High
status: New → In Progress
Martin Pitt (pitti)
Changed in ubuntuone-control-panel (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
status: Triaged → In Progress
Changed in ubuntuone-client (Ubuntu):
status: Triaged → In Progress
Revision history for this message
Martin Pitt (pitti) wrote :

sso-client fix landed in upstream trunk.

Changed in ubuntu-sso-client (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Ken VanDine (ken-vandine) wrote :

gwibber-accounts uses gir1.2-wnck-1.0 and pygtk, we need to revert to using python-wnck again.

Changed in gwibber (Ubuntu):
assignee: nobody → Ken VanDine (ken-vandine)
importance: Undecided → High
status: New → Triaged
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gwibber - 3.1.5.1-0ubuntu1

---------------
gwibber (3.1.5.1-0ubuntu1) oneiric; urgency=low

  * New upstream release
    - tile sizing fixes, getting rid of wasted space
    - revert back to python-wnck, we can't mix GIR and static
      bindings (LP: #829186)
    - use subprocess instead of Gio for handling gsettings. We can't mix GIR
      and static bindings (LP: #829186)
    - Fixes escaping of html elements properly (LP: #825204)
    - Fixed data type checks that were causing failures (LP: #830839)
    - Make sure we get time from the right json object
    - Lots of json warnings and criticals cleaned up
    - Don't crash the service if notifications fail (LP: #727568)
  * debian/control
    - Depend on python-wnck instead of gir1.2-wnck-1.0
 -- Ken VanDine <email address hidden> Tue, 23 Aug 2011 11:49:50 -0400

Changed in gwibber (Ubuntu):
status: Triaged → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubiquity - 2.7.16

---------------
ubiquity (2.7.16) oneiric; urgency=low

  [ Colin Watson ]
  * Update translations from Launchpad.
  * Enable code in console-setup 1.57ubuntu24 to fix default keyboard
    selection for language/country combinations lacking a proper combined
    locale (LP: #814448).
  * Rename libwebcam to libubiwebcam to avoid clashing with the existing
    libwebcam0 package.

  [ Evan Dandrea ]
  * Move noninteractive frontend to PyGI bindings for GObject (LP:
    #829186).
  * Make the webcam page match its specified design.
  * Automatic update of included source packages: console-setup
    1.57ubuntu25.

  [ Jeremy Bicha ]
  * Allow users to enter their own mount point in the partitoner (LP: #831431)
 -- Evan Dandrea <email address hidden> Wed, 24 Aug 2011 13:58:08 +0100

Changed in ubiquity (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

ubuntuone-client fix was merged upstream.

Changed in ubuntuone-client (Ubuntu):
status: In Progress → Fix Committed
Changed in ubuntuone-control-panel:
status: New → Fix Committed
Martin Pitt (pitti)
Changed in ubuntuone-control-panel (Ubuntu):
status: In Progress → Fix Committed
dobey (dobey)
Changed in ubuntu-sso-client:
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → Medium
status: New → Fix Committed
Changed in ubuntuone-control-panel:
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → Medium
Changed in ubuntuone-client:
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → Medium
status: New → Fix Committed
Revision history for this message
Martin Pitt (pitti) wrote :

Drat, when I upgrade today's live CD to the new pygobject packages from ppa:ubuntu-desktop/ppa, ubiquity silently exits immediately after start. I see a segfault in strace from a child process. This needs to be investigated/fixed before we can land this.

Changed in ubiquity (Ubuntu):
status: Fix Released → Triaged
dobey (dobey)
Changed in ubuntu-sso-client:
milestone: none → 1.3.3
dobey (dobey)
Changed in ubuntu-sso-client:
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntu-sso-client - 1.3.3-0ubuntu1

---------------
ubuntu-sso-client (1.3.3-0ubuntu1) oneiric; urgency=low

  * New upstream release.
    - Work correctly with static and GI bindings of gobject (LP: #829186)
 -- Rodney Dawes <email address hidden> Thu, 25 Aug 2011 21:18:50 +0200

Changed in ubuntu-sso-client (Ubuntu):
status: Fix Committed → Fix Released
dobey (dobey)
Changed in ubuntuone-control-panel:
milestone: none → 1.1.3
dobey (dobey)
Changed in ubuntuone-control-panel:
status: Fix Committed → Fix Released
dobey (dobey)
Changed in ubuntuone-client:
milestone: none → 1.7.2
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntuone-control-panel - 1.1.3-0ubuntu1

---------------
ubuntuone-control-panel (1.1.3-0ubuntu1) oneiric; urgency=low

  * New upstream release.
    - Work correctly with static and GI bindings of gobject (LP: #829186)
 -- Rodney Dawes <email address hidden> Thu, 25 Aug 2011 21:53:01 +0200

Changed in ubuntuone-control-panel (Ubuntu):
status: Fix Committed → Fix Released
dobey (dobey)
Changed in ubuntuone-client:
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntuone-client - 1.7.2-0ubuntu1

---------------
ubuntuone-client (1.7.2-0ubuntu1) oneiric; urgency=low

  * New upstream release.
    - Work correctly with static and GI bindings of gobject (LP: #829186)
 -- Rodney Dawes <email address hidden> Thu, 25 Aug 2011 16:11:47 -0400

Changed in ubuntuone-client (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

I narrowed down the ubiquity crash. It's apparently related to the custom widgets. If I update a live system to ppa:ubuntu-desktop/ppa, I get a proper crash with

PYTHONPATH=/usr/lib/ubiquity python
>>> from gi.repository import Gtk
>>> import ubiquity.gtkwidgets
>>> b = Gtk.Builder()
>>> b.add_from_file('/usr/share/ubiquity/gtk/stepPrepare.ui')
Segmentation fault (core dumped)

Revision history for this message
Martin Pitt (pitti) wrote :

Easier reproducer in a built ubiquity tree:

$ GI_TYPELIB_PATH=src/webcam PYTHONPATH=. python -c 'from gi.repository import Gtk; import ubiquity.gtkwidgets; b=Gtk.Builder(); b.add_from_file("gui/gtk/stepPrepare.ui")'

Revision history for this message
Martin Pitt (pitti) wrote :

Bisected to http://git.gnome.org/browse/pygobject/commit/?id=7bc4122897. At this point it's clearly a bug in pygobject or GTK, not in ubiquity. I created a separate bug 834168 for this and close the ubiquity task here again.

Changed in ubiquity (Ubuntu):
status: Triaged → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

Now that I do have a workaround for the ubiquity crash, I noticed that ubiquity still imports a static module: ubiquity/misc.py uses "xklavier". When I comment out that functionality, ubiquity runs fine with pygobject 2.90 (with the workaround).

Changed in ubiquity (Ubuntu):
status: Fix Released → Triaged
Revision history for this message
Martin Pitt (pitti) wrote :

For ubiquity's xklavier usage, it seems that this isn't working at all right now. With the existing pygobject 2.28 on oneiric, when I do

>>> from gi.repository import Gdk
>>> import xklavier
>>> display = Gdk.Display.get_default()
>>> engine = xklavier.Engine(display)
__main__:1: Warning: cannot register existing type `GdkDisplay'
__main__:1: Warning: g_once_init_leave: assertion `initialization_value != 0' failed
__main__:1: invalid cast from `GdkX11Display' to `invalid'

and then it hangs eternally. When I run the same with pygobject 2.90, I get

>>> from gi.repository import Gdk
>>> import xklavier
/usr/lib/python2.7/dist-packages/gobject/constants.py:24: Warning: g_boxed_type_register_static: assertion `g_type_from_name (name) == 0' failed
  import gobject._gobject
>>> display = Gdk.Display.get_default()
>>> engine = xklavier.Engine(display)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: must be gobject.GObject, not gtk.gdk.X11Display

However, even if that would work, ubiquity's set_indicator_keymaps() currently uses gconf, but the current GNOME desktop uses gsettings.

As the function does not seem to work at all in any circumstance now, would it be ok to disable it for now with

--- ubiquity/misc.py 2011-06-02 10:57:49 +0000
+++ ubiquity/misc.py 2011-08-26 07:23:25 +0000
@@ -561,6 +561,10 @@
     return model

 def set_indicator_keymaps(locale):
+ import warnings
+ warning.warn('set_indicator_keymaps: this function currently does not work')
+ return
+
     import libxml2
     import xklavier
     from gi.repository import Gdk

Revision history for this message
Martin Pitt (pitti) wrote :

In ubiquity we also need a slight API fix for Gdk.color_parse(), I did that and the previous set_indicator_keymaps() in attached branch.

Revision history for this message
Martin Pitt (pitti) wrote :

ubiquity fix available in my branch, see linked merge proposal. Evan/Colin, can you please merge this soon to unbreak the daily CDs? Thanks!

Revision history for this message
Stéphane Graber (stgraber) wrote :

Hi Martin, I just merged lp:~pitti/ubiquity/pygobject-2.90 into ubiquity's trunk.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubiquity - 2.7.26

---------------
ubiquity (2.7.26) oneiric; urgency=low

  [ Evan Dandrea ]
  * Don't show the wireless page if there's already a network connection
    (LP: #838549).

  [ Martin Pitt ]
  * ubiquity/gtkwidgets.py: Fix return value evaluation of Gdk.color_parse()
    (API was fixed to not return a separate "success" flag any more).
  * ubiquity/misc.py: Disable set_indicator_keymaps() for now. It does not
    work with either the old (2.28) nor the current (2.90) pygobject, and
    still uses gconf. (LP: #829186)

  [ Stéphane Graber ]
  * Fix crash in the KDE crash dialog.
 -- Stephane Graber <email address hidden> Mon, 05 Sep 2011 10:56:43 -0400

Changed in ubiquity (Ubuntu):
status: Triaged → Fix Released
Revision history for this message
Michael Blank (mblank) wrote :

I get this error when starting a "quickly" project:

$ quickly run
Traceback (most recent call last):
  File "bin/jotty", line 32, in <module>
    import jotty
  File "/home/mblank/jotty/jotty/__init__.py", line 14, in <module>
    from jotty import JottyWindow
  File "/home/mblank/jotty/jotty/JottyWindow.py", line 14, in <module>
    from jotty_lib import Window
  File "/home/mblank/jotty/jotty_lib/__init__.py", line 9, in <module>
    from . helpers import set_up_logging
  File "/home/mblank/jotty/jotty_lib/helpers.py", line 13, in <module>
    from . Builder import Builder
  File "/home/mblank/jotty/jotty_lib/Builder.py", line 8, in <module>
    from gi.repository import GObject # pylint: disable=E0611
  File "/usr/lib/python2.7/dist-packages/gi/__init__.py", line 23, in <module>
    from ._gi import _API, Repository
ImportError: could not import gobject (error was: ImportError('When using gi.repository you must not import static modules like "gobject". Please change all occurrences of "import gobject" to "from gi.repository import GObject".',))

Revision history for this message
Martin Pitt (pitti) wrote :

Michael Blank [2011-09-26 12:22 -0000]:
> I get this error when starting a "quickly" project:

Today's quickly upload says that this should be fixed now?

Revision history for this message
Michael Blank (mblank) wrote :

Yes, Martin, it is fixed now. New "quickly" projects run fine.

However, when I try to run/design an old project (2 weeks old, made when I was still running 11.04 ), the error still exists.

?? Is there a way to "upgrade" (or "manual" edit) a quickly project?

Revision history for this message
Martin Pitt (pitti) wrote :

 subscribe mterry

Michael Blank [2011-09-26 17:02 -0000]:
> ?? Is there a way to "upgrade" (or "manual" edit) a quickly project?

I don't know. Mike?

Revision history for this message
flcable (flcable1) wrote :

Traceback (most recent call last):
  File "/usr/bin/software-center", line 25, in <module>
    from gi.repository import Gtk, GObject
  File "/usr/lib/python2.7/dist-packages/gi/__init__.py", line 27, in <module>
    from ._gi import _API
ImportError: could not import gobject (error was: 'cannot import name __all__')

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.