GNOME Bugzilla – Bug 652860
errors in pygi-convert.sh
Last modified: 2013-02-27 14:28:55 UTC
There are several errors in pygi-convert.sh which now cause me extra work. I got the shell from the link on pygobject website 1/ -pe "s/pack_start\(([^,\)]*)\)/pack_start\(\1, True, True, 0\)/g;" \ In my case this causes things to pack_start(gtk.Label("test"),False) to become pack_start(Gtk.Label("test",True, True, 0),False) 2/ -pe "s/([^\.^ ]*)\.drag_dest_set\(/Gtk.drag_dest_set\(\1, /g;" \ Gtk.drag_dest_set does not exist. Nothing should change for drag_dest_set Same for -pe "s/self.drag_source_unset\(\)/Gtk.drag_source_unset\(self\)/g;" \ -pe "s/self.drag_dest_unset\(\)/Gtk.drag_dest_unset\(self\)/g;" \
Dropped drag methods in http://git.gnome.org/browse/pygobject/commit/?id=e03284f852f0e404cc91374f3e2e42b0ac1977b4 These were correct at the time when they got introduced, but since then the drag functions were fixed to be proper methods. pack_start() is harder to fix with a simple sed. It is currently set up to fix the most common case without using the pygtk default arguments. Keeping bug open for this part.
The drag methods were fixed, and pack_start() is unfixable without completely redesigning pygi-convert.sh. Many FOSS projects were converted ages ago, so spending lots of time on this isn't worth it any more IMHO. If someone wants to work on this though, please reopen. Thanks for the report!