mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-10-10 15:27:53 -06:00
Fix crash handler to not complain about debug_mode not being set
This commit is contained in:
parent
b88950a732
commit
a435004459
1 changed files with 3 additions and 4 deletions
|
@ -8,11 +8,10 @@ from PyQt5.QtWidgets import QDialog, QDialogButtonBox, QVBoxLayout, QLabel, QTex
|
||||||
from UM.i18n import i18nCatalog
|
from UM.i18n import i18nCatalog
|
||||||
catalog = i18nCatalog("cura")
|
catalog = i18nCatalog("cura")
|
||||||
|
|
||||||
debug_mode = False
|
|
||||||
|
|
||||||
def show(exception_type, value, tb):
|
def show(exception_type, value, tb):
|
||||||
if QCoreApplication.instance() and QCoreApplication.instance().getCommandLineOption("debug-mode", False):
|
debug_mode = False
|
||||||
debug_mode = True
|
if QCoreApplication.instance():
|
||||||
|
debug_mode = QCoreApplication.instance().getCommandLineOption("debug-mode", False)
|
||||||
|
|
||||||
traceback.print_exception(exception_type, value, tb)
|
traceback.print_exception(exception_type, value, tb)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue