diff --git a/.vscode/launch.json b/.vscode/launch.json index e80f071..1ded7e8 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -8,7 +8,7 @@ "name": "Python: Aktuelle Datei", "type": "python", "request": "launch", - "program": "debug.py", + "program": "run.py", "console": "integratedTerminal" } ] diff --git a/gui/gui.py b/gui/gui.py index be75a25..e8786d3 100644 --- a/gui/gui.py +++ b/gui/gui.py @@ -241,10 +241,11 @@ class Gui: except InterpreterException: logging.error( ('||InterpreterException|| Failed to create Image with values = ' + str(values))) - except: + except Exception as e: logging.error( ('Failed to create Image with values = ' + str(values))) - sg.popup_error(('Failed to create an image. ')) + sg.popup_error(('Failed to create an image. ' + str(e))) + except: raise elif values['-JAVA FOLDER-']: @@ -289,7 +290,11 @@ class Gui: except FileNotFoundError: sg.popup_error('FileNotFoundError', title='FileNotFoundError',) + except Exception as e: + sg.popup_cancel(str(e), title='Error') + logging.error('Try to open a .png. {e}') except: + logging.error('Try to open a .png. Unknown error.') pass if event == '-JAVA FOLDER-':