diff options
| -rw-r--r-- | bitbake/lib/bb/fetch2/__init__.py | 17 | 
1 files changed, 10 insertions, 7 deletions
| diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py index d9e4bc7ac6..54812eec43 100644 --- a/bitbake/lib/bb/fetch2/__init__.py +++ b/bitbake/lib/bb/fetch2/__init__.py | |||
| @@ -37,25 +37,28 @@ __version__ = "2" | |||
| 37 | 37 | ||
| 38 | logger = logging.getLogger("BitBake.Fetch") | 38 | logger = logging.getLogger("BitBake.Fetch") | 
| 39 | 39 | ||
| 40 | class MalformedUrl(Exception): | 40 | class BBFetchException(Exception): | 
| 41 | """Class all fetch exceptions inherit from""" | ||
| 42 | |||
| 43 | class MalformedUrl(BBFetchException): | ||
| 41 | """Exception raised when encountering an invalid url""" | 44 | """Exception raised when encountering an invalid url""" | 
| 42 | 45 | ||
| 43 | class FetchError(Exception): | 46 | class FetchError(BBFetchException): | 
| 44 | """Exception raised when a download fails""" | 47 | """Exception raised when a download fails""" | 
| 45 | 48 | ||
| 46 | class NoMethodError(Exception): | 49 | class NoMethodError(BBFetchException): | 
| 47 | """Exception raised when there is no method to obtain a supplied url or set of urls""" | 50 | """Exception raised when there is no method to obtain a supplied url or set of urls""" | 
| 48 | 51 | ||
| 49 | class MissingParameterError(Exception): | 52 | class MissingParameterError(BBFetchException): | 
| 50 | """Exception raised when a fetch method is missing a critical parameter in the url""" | 53 | """Exception raised when a fetch method is missing a critical parameter in the url""" | 
| 51 | 54 | ||
| 52 | class ParameterError(Exception): | 55 | class ParameterError(BBFetchException): | 
| 53 | """Exception raised when a url cannot be proccessed due to invalid parameters.""" | 56 | """Exception raised when a url cannot be proccessed due to invalid parameters.""" | 
| 54 | 57 | ||
| 55 | class MD5SumError(Exception): | 58 | class MD5SumError(BBFetchException): | 
| 56 | """Exception raised when a MD5SUM of a file does not match the expected one""" | 59 | """Exception raised when a MD5SUM of a file does not match the expected one""" | 
| 57 | 60 | ||
| 58 | class InvalidSRCREV(Exception): | 61 | class InvalidSRCREV(BBFetchException): | 
| 59 | """Exception raised when an invalid SRCREV is encountered""" | 62 | """Exception raised when an invalid SRCREV is encountered""" | 
| 60 | 63 | ||
| 61 | def decodeurl(url): | 64 | def decodeurl(url): | 
