]> git.ipfire.org Git - pakfire.git/blame - python/pakfire/errors.py
Compress/uncompress files on the fly.
[pakfire.git] / python / pakfire / errors.py
CommitLineData
47a4cb89 1#!/usr/bin/python
b792d887
MT
2###############################################################################
3# #
4# Pakfire - The IPFire package management system #
5# Copyright (C) 2011 Pakfire development team #
6# #
7# This program is free software: you can redistribute it and/or modify #
8# it under the terms of the GNU General Public License as published by #
9# the Free Software Foundation, either version 3 of the License, or #
10# (at your option) any later version. #
11# #
12# This program is distributed in the hope that it will be useful, #
13# but WITHOUT ANY WARRANTY; without even the implied warranty of #
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
15# GNU General Public License for more details. #
16# #
17# You should have received a copy of the GNU General Public License #
18# along with this program. If not, see <http://www.gnu.org/licenses/>. #
19# #
20###############################################################################
47a4cb89 21
60845a36
MT
22from i18n import _
23
94438733
MT
24class commandTimeoutExpired(Exception):
25 pass # XXX cannot be as is
26
47a4cb89 27class Error(Exception):
60845a36
MT
28 exit_code = 1
29
30 message = _("An unhandled error occured.")
31
32
1e80d5d7
MT
33class ActionError(Error):
34 pass
47a4cb89 35
3ad4bb5a
MT
36class BuildAbortedException(Error):
37 pass
38
47a4cb89
MT
39class BuildError(Error):
40 pass
41
42class BuildRootLocked(Error):
43 pass
44
97d7d682
MT
45class CompressionError(Error):
46 message = _("Could not compress/decompress data.")
47
48
47a4cb89
MT
49class ConfigError(Error):
50 pass
51
cabf1fbe
MT
52class DatabaseError(Error):
53 pass
54
348d903a 55class DependencyError(Error):
60845a36
MT
56 exit_code = 4
57
58 message = _("One or more dependencies could not been resolved.")
348d903a 59
47a4cb89
MT
60class DownloadError(Error):
61 pass
62
9e8b1d7a
MT
63class FileError(Error):
64 pass
65
7c8f2953
MT
66class FileNotFoundError(Error):
67 pass
68
7b1e25fd
MT
69class NotAnIPFireSystemError(Error):
70 pass
71
6a509182
MT
72class OfflineModeError(Error):
73 message = _("The requested action cannot be done on offline mode.\n"
74 "Please connect your system to the network, remove --offline from the"
75 " command line and try again.")
76
c07a3ca7
MT
77class PackageFormatUnsupportedError(Error):
78 pass
79
f781b1ab
MT
80class PakfireError(Error):
81 pass
82
936f6b37
MT
83
84class PakfireContainerError(Error):
85 message = _("Running pakfire-build in a pakfire container?")
862bea4d
MT
86
87
88class TransactionCheckError(Error):
89 message = _("Transaction test was not successful")