@@ -16,18 +16,20 @@ const (
16
16
// application being created already exists.
17
17
ApplicationAlreadyExists = errors .ConstError ("application already exists" )
18
18
19
- // ApplicationNotAlive describes an error that occurs when trying to update an application that is not alive.
19
+ // ApplicationNotAlive describes an error that occurs when trying to update
20
+ // an application that is not alive.
20
21
ApplicationNotAlive = errors .ConstError ("application is not alive" )
21
22
22
23
// ApplicationHasUnits describes an error that occurs when the application
23
24
// being deleted still has associated units.
24
25
ApplicationHasUnits = errors .ConstError ("application has units" )
25
26
26
- // ScalingStateInconsistent is returned by SetScalingState when the scaling state
27
- // is inconsistent with the application scale.
27
+ // ScalingStateInconsistent is returned by SetScalingState when the scaling
28
+ // state is inconsistent with the application scale.
28
29
ScalingStateInconsistent = errors .ConstError ("scaling state is inconsistent" )
29
30
30
- // ScaleChangeInvalid is returned when an attempt is made to set an invalid application scale value.
31
+ // ScaleChangeInvalid is returned when an attempt is made to set an invalid
32
+ // application scale value.
31
33
ScaleChangeInvalid = errors .ConstError ("scale change invalid" )
32
34
33
35
// MissingStorageDirective describes an error that occurs when expected
@@ -42,37 +44,39 @@ const (
42
44
// not valid.
43
45
ApplicationIDNotValid = errors .ConstError ("application ID not valid" )
44
46
45
- // UnitNotFound describes an error that occurs when the unit being operated on
46
- // does not exist.
47
+ // UnitNotFound describes an error that occurs when the unit being operated
48
+ // on does not exist.
47
49
UnitNotFound = errors .ConstError ("unit not found" )
48
50
49
51
// UnitAlreadyExists describes an error that occurs when the
50
52
// unit being created already exists.
51
53
UnitAlreadyExists = errors .ConstError ("unit already exists" )
52
54
53
- // UnitNotAssigned describes an error that occurs when the unit being operated on
54
- // is not assigned.
55
+ // UnitNotAssigned describes an error that occurs when the unit being
56
+ // operated on is not assigned.
55
57
UnitNotAssigned = errors .ConstError ("unit not assigned" )
56
58
57
- // UnitHasSubordinates describes an error that occurs when trying to set a unit's life
58
- // to Dead but it still has subordinates.
59
+ // UnitHasSubordinates describes an error that occurs when trying to set a
60
+ // unit's life to Dead but it still has subordinates.
59
61
UnitHasSubordinates = errors .ConstError ("unit has subordinates" )
60
62
61
- // UnitHasStorageAttachments describes an error that occurs when trying to set a unit's life
62
- // to Dead but it still has storage attachments.
63
+ // UnitHasStorageAttachments describes an error that occurs when trying to
64
+ // set a unit's life to Dead but it still has storage attachments.
63
65
UnitHasStorageAttachments = errors .ConstError ("unit has storage attachments" )
64
66
65
- // UnitIsAlive describes an error that occurs when trying to remove a unit that is still alive.
67
+ // UnitIsAlive describes an error that occurs when trying to remove a unit
68
+ // that is still alive.
66
69
UnitIsAlive = errors .ConstError ("unit is alive" )
67
70
68
- // InvalidApplicationState describes an error where the application state is invalid.
69
- // There are missing required fields.
71
+ // InvalidApplicationState describes an error where the application state is
72
+ // invalid. There are missing required fields.
70
73
InvalidApplicationState = errors .ConstError ("invalid application state" )
71
74
72
75
// CharmNotValid describes an error that occurs when the charm is not valid.
73
76
CharmNotValid = errors .ConstError ("charm not valid" )
74
77
75
- // CharmOriginNotValid describes an error that occurs when the charm origin is not valid.
78
+ // CharmOriginNotValid describes an error that occurs when the charm origin
79
+ // is not valid.
76
80
CharmOriginNotValid = errors .ConstError ("charm origin not valid" )
77
81
78
82
// CharmNameNotValid describes an error that occurs when attempting to get
@@ -83,7 +87,8 @@ const (
83
87
// a charm using an invalid charm source.
84
88
CharmSourceNotValid = errors .ConstError ("charm source not valid" )
85
89
86
- // CharmNotFound describes an error that occurs when a charm cannot be found.
90
+ // CharmNotFound describes an error that occurs when a charm cannot be
91
+ // found.
87
92
CharmNotFound = errors .ConstError ("charm not found" )
88
93
89
94
// LXDProfileNotFound describes an error that occurs when an LXD profile
@@ -94,16 +99,20 @@ const (
94
99
// exists for the given natural key.
95
100
CharmAlreadyExists = errors .ConstError ("charm already exists" )
96
101
97
- // CharmRevisionNotValid describes an error that occurs when attempting to get
98
- // a charm using an invalid revision.
102
+ // CharmRevisionNotValid describes an error that occurs when attempting to
103
+ // get a charm using an invalid revision.
99
104
CharmRevisionNotValid = errors .ConstError ("charm revision not valid" )
100
105
101
- // CharmMetadataNotValid describes an error that occurs when the charm metadata
102
- // is not valid.
106
+ // CharmMetadataNotValid describes an error that occurs when the charm
107
+ // metadata is not valid.
103
108
CharmMetadataNotValid = errors .ConstError ("charm metadata not valid" )
104
109
105
- // CharmManifestNotValid describes an error that occurs when the charm manifest
106
- // is not valid.
110
+ // CharmManifestNotFound describes an error that occurs when the charm
111
+ // manifest is not found.
112
+ CharmManifestNotFound = errors .ConstError ("charm manifest not found" )
113
+
114
+ // CharmManifestNotValid describes an error that occurs when the charm
115
+ // manifest is not valid.
107
116
CharmManifestNotValid = errors .ConstError ("charm manifest not valid" )
108
117
109
118
// CharmBaseNameNotValid describes an error that occurs when the charm base
@@ -118,18 +127,18 @@ const (
118
127
// has multiple relations with the same name
119
128
CharmRelationNameConflict = errors .ConstError ("charm relation name conflict" )
120
129
121
- // CharmRelationReservedNameMisuse describes an error that occurs when the charm
122
- // relation name is a reserved name which it is not allowed to use.
130
+ // CharmRelationReservedNameMisuse describes an error that occurs when the
131
+ // charm relation name is a reserved name which it is not allowed to use.
123
132
CharmRelationReservedNameMisuse = errors .ConstError ("charm relation reserved name misuse" )
124
133
125
134
// CharmRelationRoleNotValid describes an error that occurs when the charm
126
135
// relation roles is not valid. Either it is an unknown role, or it has the
127
136
// wrong value.
128
137
CharmRelationRoleNotValid = errors .ConstError ("charm relation role not valid" )
129
138
130
- // MultipleCharmHashes describes and error that occurs when a charm has multiple
131
- // hash values. At the moment, we only support sha256 hash format, so if another
132
- // is found, an error is returned.
139
+ // MultipleCharmHashes describes and error that occurs when a charm has
140
+ // multiple hash values. At the moment, we only support sha256 hash format,
141
+ // so if another is found, an error is returned.
133
142
MultipleCharmHashes = errors .ConstError ("multiple charm hashes found" )
134
143
135
144
// ResourceNotFound describes an error that occurs when a resource is
@@ -169,4 +178,8 @@ const (
169
178
// resolved. This means the charm for the hash does not exist and needs to
170
179
// be downloaded.
171
180
CharmNotResolved = errors .ConstError ("charm not resolved" )
181
+
182
+ // CharmDownloadInfoNotFound describes an error that occurs when the charm
183
+ // download info is not found.
184
+ CharmDownloadInfoNotFound = errors .ConstError ("charm download info not found" )
172
185
)
0 commit comments