Переглянути джерело

Merged jpcgt/flatcam/Beta into Beta

Marius Stanciu 6 роки тому
батько
коміт
392a58bf47
1 змінених файлів з 3 додано та 2 видалено
  1. 3 2
      FlatCAMApp.py

+ 3 - 2
FlatCAMApp.py

@@ -8199,8 +8199,9 @@ class App(QtCore.QObject):
                 with lzma.open(filename) as f:
                 with lzma.open(filename) as f:
                     file_content = f.read().decode('utf-8')
                     file_content = f.read().decode('utf-8')
                     d = json.loads(file_content, object_hook=dict2obj)
                     d = json.loads(file_content, object_hook=dict2obj)
-            except IOError:
-                App.log.error("Failed to open project file: %s" % filename)
+
+            except Exception as e:
+                App.log.error("Failed to open project file: %s with error: %s" % (filename, str(e)))
                 self.inform.emit(_("[ERROR_NOTCL] Failed to open project file: %s") % filename)
                 self.inform.emit(_("[ERROR_NOTCL] Failed to open project file: %s") % filename)
                 return
                 return