From 346dfe1c7fb3697f2916914d33070bf87c7c84a4 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Tue, 26 Aug 2014 15:25:22 +0900 Subject: [PATCH] start new instance if existing instance hung --- aqt/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/aqt/__init__.py b/aqt/__init__.py index 61aa24158..c5de6ee2e 100644 --- a/aqt/__init__.py +++ b/aqt/__init__.py @@ -152,7 +152,8 @@ class AnkiApp(QApplication): return False sock.write(txt) if not sock.waitForBytesWritten(self.TMOUT): - raise Exception("existing instance not emptying") + # existing instance running but hung + return False sock.disconnectFromServer() return True