mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-25 01:02:15 +00:00
33 lines
1.2 KiB
Rust
33 lines
1.2 KiB
Rust
#[derive(Debug, thiserror::Error)]
|
|
pub enum Error {
|
|
#[error("encrypted environment value is missing")]
|
|
MissingCiphertext,
|
|
#[error("ciphertext is not valid base64 for the configured manager")]
|
|
InvalidCiphertext,
|
|
#[error("decrypted value is not UTF-8")]
|
|
Utf8,
|
|
#[error("unsupported OIDC provider or missing build feature")]
|
|
UnsupportedOidc,
|
|
#[error("OIDC reference requires a provider and audience")]
|
|
InvalidOidc,
|
|
#[error("OIDC environment variable is missing")]
|
|
MissingEnvironment,
|
|
#[error("OIDC request failed")]
|
|
OidcHttp,
|
|
#[error("OIDC provider returned HTTP {0}")]
|
|
OidcStatus(u16),
|
|
#[error("OIDC response is invalid")]
|
|
OidcResponse,
|
|
#[error("OIDC file path must be absolute and within the credential allowlist")]
|
|
UnsafeOidcPath,
|
|
#[error("OIDC file could not be read")]
|
|
OidcFile,
|
|
#[error("secret cannot be converted to {expected}")]
|
|
TypeMismatch { expected: &'static str },
|
|
#[cfg(feature = "aws")]
|
|
#[error(transparent)]
|
|
Aws(#[from] litellm_secrets_aws::Error),
|
|
#[cfg(feature = "google")]
|
|
#[error(transparent)]
|
|
Google(#[from] litellm_secrets_google::Error),
|
|
}
|