import sys
import logging
-from wic.errors import CreatorError
+from wic.errors import WicError
from wic import pluginbase
from wic.utils.misc import get_bitbake_var
""" the return value is dict of name:class pairs """
if ptype not in PLUGIN_TYPES:
- raise CreatorError('%s is not valid plugin type' % ptype)
+ raise WicError('%s is not valid plugin type' % ptype)
plugins_dir = self._build_plugin_dir_list(self.plugin_dir, ptype)
from time import strftime
-from wic.errors import ImageError, WicError
+from wic.errors import WicError
from wic.filemap import sparse_copy
from wic.ksparser import KickStart, KickStartError
from wic.plugin import pluginmgr
# The --part-type can also be implemented for MBR partitions,
# in which case it would map to the 1-byte "partition type"
# filed at offset 3 of the partition entry.
- raise ImageError("setting custom partition type is not " \
- "implemented for msdos partitions")
+ raise WicError("setting custom partition type is not " \
+ "implemented for msdos partitions")
# Get the disk where the partition is located
self.numpart += 1
import os
from wic.engine import get_custom_config
-from wic.errors import ImageError, WicError
+from wic.errors import WicError
from wic.utils import runner
from wic.pluginbase import SourcePlugin
from wic.utils.misc import (exec_cmd, exec_native_cmd,
rcode = runner.show(['dd', 'if=%s' % mbrfile,
'of=%s' % full_path, 'conv=notrunc'])
if rcode != 0:
- raise ImageError("Unable to set MBR to %s" % full_path)
+ raise WicError("Unable to set MBR to %s" % full_path)
@classmethod
def do_configure_partition(cls, part, source_params, creator, cr_workdir,
import os
import re
-from wic.errors import ImageError, WicError
+from wic.errors import WicError
from wic.utils import runner
from wic.utils.misc import get_bitbake_var, exec_cmd, exec_native_cmd
from wic.pluginbase import SourcePlugin
ret_code = runner.show(['dd', 'if=%s' % mbrfile, 'of=%s' % full_path, 'conv=notrunc'])
if ret_code != 0:
- raise ImageError("Unable to set MBR to %s" % full_path)
+ raise WicError("Unable to set MBR to %s" % full_path)