From dd02243790b1952c21ec4c95c7ac84d7625ae593 Mon Sep 17 00:00:00 2001 From: Thomas Karl Pietrowski Date: Mon, 5 Sep 2016 18:54:52 +0200 Subject: [PATCH] SliceInfo: Adding log message and pass exception * removes unused "e" * Using logException correctly Conflicts: plugins/SliceInfoPlugin/SliceInfo.py --- plugins/SliceInfoPlugin/SliceInfo.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/plugins/SliceInfoPlugin/SliceInfo.py b/plugins/SliceInfoPlugin/SliceInfo.py index d30425d0ac..700d90822a 100644 --- a/plugins/SliceInfoPlugin/SliceInfo.py +++ b/plugins/SliceInfoPlugin/SliceInfo.py @@ -84,14 +84,13 @@ class SliceInfo(Extension): return # Do nothing, user does not want to send data # Listing all files placed on the buildplate - filenames = [] + modelhashes = [] for node in DepthFirstIterator(CuraApplication.getInstance().getController().getScene().getRoot()): if type(node) is not SceneNode or not node.getMeshData(): - continue - filenames.append(node.getMeshData().getFileName()) + continue + modelhashes.append(node.getMeshData().getHash()) # Creating md5sums and formatting them as discussed on JIRA - modelhashes = [hashlib.md5(open(filename, 'rb').read()).hexdigest() for filename in filenames] modelhash_formatted = "" if modelhashes: modelhash_formatted = str(modelhashes[0])