1
2 """
3
4 @author: Fabio Erculiani <lxnay@sabayonlinux.org>
5 @contact: lxnay@sabayonlinux.org
6 @copyright: Fabio Erculiani
7 @license: GPL-2
8
9 B{Entropy Framework exceptions class module}
10
11 This module contains Entropy Framework exceptions classes.
12
13 """
14 from entropy.const import const_isstring, const_convert_to_unicode
15
17 """Dumb exception class"""
18
20 """General superclass for Entropy exceptions"""
22 self.value = value
23 Exception.__init__(self)
24
29
31 if const_isstring(self.value):
32 return self.value
33 return repr(self.value)
34
36 """Corruption indication"""
37
39 """On-Disk cache Corruption indication"""
40
42 """An invalid depend string has been encountered"""
43
45 """
46 During dependencies calculation, dependencies were not found,
47 list (set) of missing dependencies are in the .value attribute
48 """
49
51 """An invalid version string has been encountered"""
52
54 """An incorrect formatting was passed instead of the expected one"""
55
57 """A parameter of the wrong type was passed"""
58
60 """A parameter is required for the action requested but was not passed"""
61
63 """An error was generated while attempting to parse the request"""
64
66 """An incorrect formatting was passed instead of the expected one"""
67
69 """An incorrect type was passed instead of the expected one"""
70
72 """Cannot open repository database"""
73
75 """ An Entropy-related error occured in EntropyRepository class methods """
76
78 """Error during EntropyRepositoryPlugin hook execution"""
79
81 """Cannot connect to service"""
82
84 """Raised to interrupt a thread or process"""
85
87 """
88 Raised when URI handler (in entropy.transceivers.EntropyTransceiver)
89 for given URI is not available.
90 """
91
94
96 """Cannot open system database"""
97
99 """Source Package Manager generic errors"""
100
103
105 """Action queue issue"""
106
108 """
109 Data was not found when it was expected to exist or
110 was specified incorrectly
111 """
112
114 """Atom not properly formatted"""
115
117 """Package set does not exist"""
118
120 """A file was not found when it was expected to exist"""
121
123 """A directory was not found when it was expected to exist"""
124
126 """An operation was not permitted operating system"""
127
129 """Permission denied"""
130 from errno import EACCES as errno
131
133 """Read-only file system"""
134
136 """A required binary was not available or executable"""
137
139 """A required library was not available or executable"""
140
142 """SSL support is not available"""
143
145 """Generic Timeout Error exception"""
146
148 """Malformed or missing package data"""
149