From: Tomas Babej Date: Sat, 8 Aug 2015 17:38:11 +0000 (+0200) Subject: backends: Move TaskWarriorException into backends X-Git-Url: https://git.madduck.net/etc/taskwarrior.git/commitdiff_plain/0531935967fd784f762215d35bcae90194e0ff90 backends: Move TaskWarriorException into backends --- diff --git a/tasklib/backends.py b/tasklib/backends.py index e5562c6..f817d4f 100644 --- a/tasklib/backends.py +++ b/tasklib/backends.py @@ -44,6 +44,10 @@ class Backend(object): pass +class TaskWarriorException(Exception): + pass + + class TaskWarrior(object): def __init__(self, data_location=None, create=True, taskrc_location='~/.taskrc'): self.taskrc_location = os.path.expanduser(taskrc_location) diff --git a/tasklib/task.py b/tasklib/task.py index d4fc9b2..4f10b9d 100644 --- a/tasklib/task.py +++ b/tasklib/task.py @@ -9,7 +9,7 @@ import six import sys import tzlocal -from backends import TaskWarrior +from backends import TaskWarrior, TaskWarriorException DATE_FORMAT = '%Y%m%dT%H%M%SZ' DATE_FORMAT_CALC = '%Y-%m-%dT%H:%M:%S' @@ -21,10 +21,6 @@ logger = logging.getLogger(__name__) local_zone = tzlocal.get_localzone() -class TaskWarriorException(Exception): - pass - - class ReadOnlyDictView(object): """ Provides simplified read-only view upon dict object.