Skip to main content

stage_to_string

Function stage_to_string 

Source
pub fn stage_to_string<S>(stage: &S) -> String
where S: ProgressStage,
Expand description

Helper to get string representation of a progress stage via serde.

Returns "<unknown_stage>" if serialization fails (should never happen with properly implemented ProgressStage types). This mirrors tool_name_to_string’s non-panicking fallback so a failing Serialize impl cannot panic the turn loop on the async-tool progress hot path.