From eb2bc68c07ad01fa5448268a2ca4f8be0ba98f39 Mon Sep 17 00:00:00 2001 From: James Lu Date: Sun, 31 Jul 2016 20:36:27 -0700 Subject: [PATCH] relay: catch errors on remove_network() and ignore them (cherry picked from commit f2a5e1dc78a31b66df58aa3fb65854fe2d87dd21) --- plugins/relay.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plugins/relay.py b/plugins/relay.py index b0e60dd..90df2d5 100644 --- a/plugins/relay.py +++ b/plugins/relay.py @@ -249,8 +249,10 @@ def spawnRelayServer(irc, remoteirc): log.exception('(%s) Failed to spawn server for %r (possible jupe?):', irc.name, remoteirc.name) # We will just bail here. Disconnect the bad network. - - control.remove_network(irc) + try: + control.remove_network(irc) + except KeyError: + pass return # Mark the server as a relay server