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 320127 - [patch] Please provide python bindings for the reaper object
[patch] Please provide python bindings for the reaper object
Status: RESOLVED WONTFIX
Product: vte
Classification: Core
Component: general
unspecified
Other All
: Normal enhancement
: ---
Assigned To: VTE Maintainers
VTE Maintainers
list-kmaraas
Depends on:
Blocks:
 
 
Reported: 2005-10-28 20:55 UTC by Michael Vogt
Modified: 2010-03-16 21:02 UTC
See Also:
GNOME target: ---
GNOME version: Unversioned Enhancement


Attachments
patch that adds access to the reaper (1.70 KB, patch)
2005-10-28 20:57 UTC, Michael Vogt
none Details | Review
newer patch (1.73 KB, patch)
2007-03-15 10:30 UTC, Guillaume Bedot
none Details | Review

Description Michael Vogt 2005-10-28 20:55:25 UTC
Please provide python bindings for the reaper object
Comment 1 Michael Vogt 2005-10-28 20:57:18 UTC
Created attachment 54016 [details] [review]
patch that adds access to the reaper
Comment 2 Guillaume Bedot 2007-03-15 10:26:26 UTC
Please do, latest ontv (2.6.0) uses it !
Comment 3 Guillaume Bedot 2007-03-15 10:30:27 UTC
Created attachment 84635 [details] [review]
newer patch
Comment 4 Chris Wilson 2007-03-15 13:58:15 UTC
Wibble. I was intending on killing VteReaper at some time since it's a large wrapper for g_child_watch_add_full(), which is available via pygobject.

Hmm, skimming ontv, it looks like it prefers connecting to the reaper's child-exited signal instead of the terminal's child-exited signal. And could be swapped over except that __grabber_command_exited uses the exit status, which is sadly lacking from the terminal child-exited signal. [But can be made available via a new getter.]

However, what I guess might be more useful would be a vte_terminal_spawn_command(vte, flags, argv, env, on_child_exit_cb).
Comment 5 Guillaume Bedot 2007-03-15 16:23:16 UTC
Well, the patch was intended for gdebi IIRC.
Maybe the ubuntu and debian people know more about this software than me.
Comment 6 Johan Svedberg 2007-03-15 19:17:08 UTC
I used the terminal's child-exited signal at first but switched over to the reaper because I needed the exit status as you noted (looked at GDebi). A vte_terminal_spawn_command sounds like a good plan Chris if the exit status can be made availible somehow.
Comment 7 Michael Vogt 2007-03-16 15:11:57 UTC
I wouldn't mind switching my code in gdebi and update-manager to g_child_watch_add_full(). But it seems to be not working currently with forkpty() (that is what we use to spawn dpkg). My child_exited function is not called.

I'm happy to attach my testcode is someone is interessted (very simple, just exchanged vte.reaper_get(); vte.reaper.connect() with gobject.child_watch_add(pid, self.child_exited))
Comment 8 Christian Persch 2008-10-12 12:46:26 UTC
Re comment 7:

There's now a way to get the child's exit status from the child-exited signal (see bug 509204).

Since the reaper is to be removed (bug 112172), I think we should WONTFIX this bug.
Comment 9 Behdad Esfahbod 2008-10-14 03:44:44 UTC
Agreed.  If someone want to do the suggested spawn_command(), open a new bug with patch.
Comment 10 Behdad Esfahbod 2008-10-14 03:44:53 UTC
Agreed.  If someone want to do the suggested spawn_command(), open a new bug with patch.