k8_config/
error.rs

1use serde_yaml::Error as SerdeYamlError;
2use std::io::Error as IoError;
3use thiserror::Error;
4
5#[derive(Error, Debug)]
6pub enum ConfigError {
7    #[error("IO error: {0}")]
8    IoError(#[from] IoError),
9    #[error("Yaml error: {0}")]
10    SerdeError(#[from] SerdeYamlError),
11    #[error("No active Kubernetes context")]
12    NoCurrentContext,
13    #[error("Unknown error: {0}")]
14    Other(String),
15}