Index: ToscaWidgets-0.9.8/tw/core/command.py
===================================================================
--- ToscaWidgets-0.9.8.orig/tw/core/command.py
+++ ToscaWidgets-0.9.8/tw/core/command.py
@@ -6,7 +6,10 @@ import sys
import os
import tempfile
import subprocess
-import md5
+try:
+ from hashlib import md5 as hash_constructor
+except ImportError:
+ from md5 import new as hash_constructor
import mimetypes
try:
@@ -547,7 +550,7 @@ class aggregate_tw_resources(Command):
# this must result in an existing variant_filename
resource_aggregator.flush()
inf = open(variant_filename)
- hash = md5.new()
+ hash = hash_constructor()
while True:
block = inf.read(4096)
if not block: