diff --git a/ipykernel/eventloops.py b/ipykernel/eventloops.py index 29434bb41..4911c87ee 100644 --- a/ipykernel/eventloops.py +++ b/ipykernel/eventloops.py @@ -285,7 +285,10 @@ def start(self): @loop_tk.exit def loop_tk_exit(kernel): - kernel.app_wrapper.app.destroy() + try: + kernel.app_wrapper.app.destroy() + except RuntimeError: + pass @register_integration('gtk')