Fixes for all of the plugins. Added a script to invoke mypy. (I'm stiiiick of .bat files. They are just broken.)

This commit is contained in:
Simon Edwards 2017-01-17 16:57:37 +01:00
parent fb70eb6813
commit 1b43e4981e
12 changed files with 62 additions and 20 deletions

View file

@ -12,10 +12,14 @@ from UM.Logger import Logger
from UM.i18n import i18nCatalog
catalog = i18nCatalog("cura")
try:
from cura.CuraVersion import CuraDebugMode
except ImportError:
CuraDebugMode = False # [CodeStyle: Reflecting imported value]
MYPY = False
if MYPY:
CuraDebugMode = False
else:
try:
from cura.CuraVersion import CuraDebugMode
except ImportError:
CuraDebugMode = False # [CodeStyle: Reflecting imported value]
# List of exceptions that should be considered "fatal" and abort the program.
# These are primarily some exception types that we simply cannot really recover from