New submission from Narnie Harshoe <signupnar...@gmail.com>: In a normal python program, Ctrl-C will set up a KeyboardInterrupt and terminate the program. This works with a normal python script, including GTK2 gtk.main(), but GTK3 Gtk.main() (even when used in a more robust GTK program that coded below) will not terminate with Ctrl-C requiring a Ctrl-Z and killing the job to terminate. See the commmand line output below:
$ python -c "while True: > pass > " ^CTraceback (most recent call last): File "<string>", line 1, in <module> KeyboardInterrupt $ python -c "import gtk > gtk.main() > " ^CTraceback (most recent call last): File "<string>", line 2, in <module> KeyboardInterrupt $ python -c "from gi.repository import Gtk > Gtk.main() > " ^C ^C ^Z [1]+ Stopped python -c "from gi.repository import Gtk Gtk.main() " $ kill %1 [1]+ Stopped python -c "from gi.repository import Gtk Gtk.main() " The behaviour under Gtk.main() should be changed to respond to the KeyboardInterrupt. ---------- components: None messages: 154427 nosy: Narnie.Harshoe priority: normal severity: normal status: open title: Ctrl-C does not terminate GTK3 Gtk.main() loop when program run from command line versions: Python 2.7 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue14138> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com