|
|
|
@ -102,6 +102,10 @@ class CommonVariableError(VariableError):
|
|
|
|
|
"""Exception for command line"""
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class BuildAlreadyInstalledError(VariableError):
|
|
|
|
|
"""Exception for install -U when used after a successful install"""
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def makePath(dirs, mode=755):
|
|
|
|
|
if not path.exists(dirs):
|
|
|
|
|
os.makedirs(dirs, mode)
|
|
|
|
@ -1990,7 +1994,8 @@ class DataVars(SimpleDataVars):
|
|
|
|
|
messages = e.exception_list if e.exception_list else [e]
|
|
|
|
|
mess = "\n".join((str(x) for x in messages))
|
|
|
|
|
mapError = {PasswordError: 'pwderror',
|
|
|
|
|
CommonVariableError: 'commonerror'}
|
|
|
|
|
CommonVariableError: 'commonerror',
|
|
|
|
|
BuildAlreadyInstalledError: 'sysinstalled'}
|
|
|
|
|
for k, v in mapError.items():
|
|
|
|
|
if (isinstance(e, k) or e.exception_list and
|
|
|
|
|
all(isinstance(x, k) for x in
|
|
|
|
|