From e4f125b44155b621d07ef7c3dc46dddd8355da57 Mon Sep 17 00:00:00 2001 From: Chris Jones Date: Wed, 24 Aug 2011 20:00:51 +0100 Subject: [PATCH] Teach create_layout() how to fail more gracefully, so DBus requests for non-existant layouts can't bring everything down --- terminatorlib/terminator.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 600bc8d2..96127b0f 100755 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -163,7 +163,8 @@ class Terminator(Borg): if not layout: # User specified a non-existent layout. default to one Terminal err('layout %s not defined' % layout) - raise(KeyError) + self.new_window() + return # Wind the flat objects into a hierarchy hierarchy = {}