GNOME Bugzilla – Bug 695199
3.7.91 regression: KeyError: 'You have tried to modify the registry outside of the overrides module. This is not allowed' with gedit
Last modified: 2013-03-05 11:14:58 UTC
From downstream bug https://bugs.launchpad.net/ubuntu/+source/pygobject/+bug/1146567: Running gedit on current raring with gedit-plugins installed and "codecomment" activated gives those errors:
+ Trace 231592
from gi.repository import GObject, Gtk, GtkSource, Gedit
dynamic_module._load()
overrides_modules = __import__('gi.overrides', fromlist=[self._namespace])
@override(Gedit.debug_plugin_message)
registry.register(type_)
self[override_class] = override_class
raise KeyError('You have tried to modify the registry outside of the overrides module. This is not allowed')
(gedit:16285): libpeas-WARNING **: Error loading plugin 'codecomment'
This looks like fallout from bug 686835, apparently Simon was right and other modules use @override with functions as well.
That's too bad, at least it was caught now! I think the whole thing will probably need to be put back because if there are overrides relying on @override also clobbering the original instead of using __all__, they will break (or the function override would not be available). The right approach to bug 686835 should probably be to stash the override in the registry instead of clobbering the original gi module, but there is also no rush for any of this...
http://git.gnome.org/browse/pygobject/commit/?id=9ab6e54