From: Ondrej Lichtner olichtne@redhat.com
This module defines the common JobError exception that will be used by both the Controller and the Slave Job classes.
Signed-off-by: Ondrej Lichtner olichtne@redhat.com --- lnst/Common/JobError.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 lnst/Common/JobError.py
diff --git a/lnst/Common/JobError.py b/lnst/Common/JobError.py new file mode 100644 index 0000000..a86a8be --- /dev/null +++ b/lnst/Common/JobError.py @@ -0,0 +1,22 @@ +""" +This module defines the common JobError exception used by both the Controller +and the Slave + +Copyright 2017 Red Hat, Inc. +Licensed under the GNU General Public License, version 2 as +published by the Free Software Foundation; see COPYING for details. +""" + +__author__ = """ +olichtne@redhat.com (Ondrej Lichtner) +""" + +from lnst.Common.LnstError import LnstError + +class JobError(LnstError): + """Base class for client errors.""" + def __init__(self, s): + self._s = s + + def __str__(self): + return "JobError: " + str(self._s)