pub enum RejectionReason {
OutOfBounds {
adjustable: Adjustable,
allowed: Range,
requested: f64,
},
ActorMayNotRequest {
action: ActionKind,
actor_class: ActorClass,
},
NoActivePrint,
InvalidFromState {
state: PrinterState,
},
MinIntervalNotElapsed {
interval_s: i64,
since_last_s: i64,
},
UnsupportedAdjustable {
adjustable: Adjustable,
},
InsufficientFilament {
buffer_g: f64,
remaining_g: f64,
required_g: f64,
spool_id: SpoolId,
spool_name: String,
tool: i64,
unverified: Option<UnverifiedReason>,
},
UnverifiedSpool {
reason: UnverifiedReason,
spool_id: SpoolId,
spool_name: String,
tool: i64,
},
AnalysisUnavailable {
file_name: String,
waited_s: i64,
},
SpoolRefused {
detail: String,
},
}Expand description
Why a request was refused.
Each rejection is a distinct variant, so a consumer distinguishes them by matching rather than by reading a message.
Variants§
OutOfBounds
The value asked for is outside the range allowed for that adjustable.
Fields
adjustable: AdjustableThe adjustable that was asked for.
ActorMayNotRequest
This actor class may not request this action at all.
Fields
action: ActionKindThe action they asked for.
actor_class: ActorClassThe class of the actor that asked.
NoActivePrint
There is no active print to act on.
InvalidFromState
The printer is not in a state this action is valid from.
Fields
state: PrinterStateThe state the printer is in.
MinIntervalNotElapsed
The agent’s minimum interval has not elapsed.
Fields
UnsupportedAdjustable
The adjustable is not one this printer has.
Fields
adjustable: AdjustableThe adjustable this printer cannot express.
InsufficientFilament
A start was refused because the spool on one tool holds less than the print needs and its buffer.
Fields
unverified: Option<UnverifiedReason>The spool’s oldest mark, when the short spool is also unverified.
UnverifiedSpool
A start was refused because the spool on one tool is unverified.
Fields
reason: UnverifiedReasonThe spool’s oldest mark.
A start was refused because OctoPrint’s analysis of the file had not
appeared when the start’s wait for it elapsed.
SpoolRefused
A spool command could not be carried out.