summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Thursfield <sam.thursfield@codethink.co.uk>2014-06-03 14:40:47 +0000
committerSam Thursfield <sam.thursfield@codethink.co.uk>2014-06-03 14:51:22 +0000
commitaf8acd80ca4326d82266f5d8fa2eca0cca1e1fbc (patch)
treecb0c67544d040219942ca7d794d8e60fbfca5f93
parent64263de0123f9e513a300fd179e5b84384fa5343 (diff)
downloadmorph-af8acd80ca4326d82266f5d8fa2eca0cca1e1fbc.tar.gz
Make all remote artifact cache get errors inherit from GetError
This saves from having to catch three separate exceptions.
-rw-r--r--morphlib/remoteartifactcache.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/morphlib/remoteartifactcache.py b/morphlib/remoteartifactcache.py
index 9f6bf69e..3fe0f444 100644
--- a/morphlib/remoteartifactcache.py
+++ b/morphlib/remoteartifactcache.py
@@ -1,4 +1,4 @@
-# Copyright (C) 2012-2013 Codethink Limited
+# Copyright (C) 2012-2014 Codethink Limited
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -36,7 +36,7 @@ class GetError(cliapp.AppException):
(artifact, artifact.cache_key, cache))
-class GetArtifactMetadataError(cliapp.AppException):
+class GetArtifactMetadataError(GetError):
def __init__(self, cache, artifact, name):
cliapp.AppException.__init__(
@@ -44,7 +44,7 @@ class GetArtifactMetadataError(cliapp.AppException):
'from the artifact cache %s' % (name, artifact, cache))
-class GetSourceMetadataError(cliapp.AppException):
+class GetSourceMetadataError(GetError):
def __init__(self, cache, source, cache_key, name):
cliapp.AppException.__init__(