Commit 0a116b9d authored by Nikos Skalkotos's avatar Nikos Skalkotos
Browse files

Fix missing imports introduced in 023e1217

parent 023e1217
......@@ -44,7 +44,8 @@ from image_creator.output.dialog import GaugeOutput, InfoBoxOutput
from image_creator.kamaki_wrapper import Kamaki, ClientError
from image_creator.help import get_help_file
from image_creator.dialog_util import SMALL_WIDTH, WIDTH, \
update_background_title, confirm_reset, confirm_exit, Reset, extract_image
update_background_title, confirm_reset, confirm_exit, Reset, \
extract_image, extract_metadata_string
CONFIGURATION_TASKS = [
("Partition table manipulation", ["FixPartitionTable"],
......@@ -106,15 +107,6 @@ class metadata_monitor(object):
d.msgbox(msg, title="Image Property Changes", width=SMALL_WIDTH)
def extract_metadata_string(session):
metadata = ['%s=%s' % (k, v) for (k, v) in session['metadata'].items()]
if 'task_metadata' in session:
metadata.extend("%s=yes" % m for m in session['task_metadata'])
return '\n'.join(metadata) + '\n'
def upload_image(session):
d = session["dialog"]
dev = session['device']
......
......@@ -34,6 +34,8 @@
# or implied, of GRNET S.A.
import os
from image_creator.output.dialog import GaugeOutput
from image_creator.util import MD5
SMALL_WIDTH = 60
WIDTH = 70
......@@ -68,6 +70,15 @@ class Reset(Exception):
pass
def extract_metadata_string(session):
metadata = ['%s=%s' % (k, v) for (k, v) in session['metadata'].items()]
if 'task_metadata' in session:
metadata.extend("%s=yes" % m for m in session['task_metadata'])
return '\n'.join(metadata) + '\n'
def extract_image(session):
d = session['dialog']
dir = os.getcwd()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment