forked from saltstack/salt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
exceptions.py
91 lines (63 loc) · 1.87 KB
/
exceptions.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
'''
This module is a central location for all salt exceptions
'''
class SaltException(Exception):
'''
Base exception class; all Salt-specific exceptions should subclass this
'''
class SaltClientError(SaltException):
'''
Problem reading the master root key
'''
class SaltMasterError(SaltException):
'''
Problem reading the master root key
'''
class AuthenticationError(SaltException):
'''
If sha256 signature fails during decryption
'''
class CommandNotFoundError(SaltException):
'''
Used in modules or grains when a required binary is not available
'''
class CommandExecutionError(SaltException):
'''
Used when a module runs a command which returns an error and wants
to show the user the output gracefully instead of dying
'''
class LoaderError(SaltException):
'''
Problems loading the right renderer
'''
class MinionError(SaltException):
'''
Minion problems reading uris such as salt:// or http://
'''
class SaltInvocationError(SaltException):
'''
Used when the wrong number of arguments are sent to modules or invalid
arguments are specified on the command line
'''
class PkgParseError(SaltException):
'''
Used when of the pkg modules cannot correctly parse the output from
the CLI tool (pacman, yum, apt, aptitude, etc)
'''
class SaltRenderError(SaltException):
'''
Used when a renderer needs to raise an explicit error
'''
class SaltReqTimeoutError(SaltException):
'''
Thrown when a salt master request call fails to return within the timeout
'''
class EauthAuthenticationError(SaltException):
'''
Thrown when eauth authentication fails
'''
class SaltSystemExit(SystemExit):
'''
This exception is raised when an unsolvable problem is found. There's
nothing else to do, salt should just exit.
'''