From 78638a28f2e4208e57c446e34846a9b17c6c818e Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 27 Feb 2023 08:13:11 +0530 Subject: [PATCH] ... --- src/calibre/gui2/toc/main.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/calibre/gui2/toc/main.py b/src/calibre/gui2/toc/main.py index fcb293c22c..3be48c992d 100644 --- a/src/calibre/gui2/toc/main.py +++ b/src/calibre/gui2/toc/main.py @@ -1127,7 +1127,7 @@ class TOCEditor(QDialog): # {{{ tb = None try: self.ebook = get_container(self.pathtobook, log=self.log) - except: + except Exception: import traceback tb = traceback.format_exc() if self.working: @@ -1162,6 +1162,15 @@ class TOCEditor(QDialog): # {{{ # }}} +def develop(): + from calibre.gui2 import Application + app = Application([]) + d = TOCEditor(sys.argv[-1]) + d.start() + d.exec() + del app + + def main(shm_name=None): import json import struct