pub struct RoverError {
pub code: &'static str,
pub message: String,
}Expand description
Stable error envelope returned over MCP. code is from the fixed set
documented in the M3 design.
Fields§
§code: &'static str§message: StringImplementations§
Source§impl RoverError
impl RoverError
pub const MAX_TOKENS_EXCEEDED: &'static str = "max_tokens_exceeded"
pub const INVALID_ARGS: &'static str = "invalid_args"
pub const INVALID_URL: &'static str = "invalid_url"
pub const SSRF_DENIED: &'static str = "ssrf_denied"
pub const FETCH_FAILED: &'static str = "fetch_failed"
pub const BOT_CHALLENGE: &'static str = "bot_challenge"
pub const EXTRACT_FAILED: &'static str = "extract_failed"
pub const STORAGE_ERROR: &'static str = "storage_error"
pub const TOKENIZER_UNAVAILABLE: &'static str = "tokenizer_unavailable"
pub const ROBOTS_DISALLOWED: &'static str = "robots_disallowed"
pub const ROBOTS_FETCH_FAILED: &'static str = "robots_fetch_failed"
pub const RETRY_EXHAUSTED: &'static str = "retry_exhausted"
pub const RATE_LIMITED: &'static str = "rate_limited"
pub const DEFERRED: &'static str = "deferred"
pub const TOO_MANY_URLS: &'static str = "too_many_urls"
pub const EMPTY_URL_LIST: &'static str = "empty_url_list"
pub const SUMMARIZER_NO_SUCH_BACKEND: &'static str = "summarizer_no_such_backend"
pub const SUMMARIZER_NO_EXTRACTIVE_FOR_FALLBACK: &'static str = "summarizer_no_extractive_backend_for_fallback"
pub const SUMMARIZER_BACKEND_UNAVAILABLE: &'static str = "summarizer_backend_unavailable"
pub const SUMMARIZER_RATE_LIMITED: &'static str = "summarizer_rate_limited"
pub const SUMMARIZER_AUTH_FAILED: &'static str = "summarizer_auth_failed"
pub const SUMMARIZER_MODEL_ERROR: &'static str = "summarizer_model_error"
pub const SUMMARIZER_INVALID_REQUEST: &'static str = "summarizer_invalid_request"
pub const SUMMARIZER_LOCAL_FEATURE_NOT_COMPILED: &'static str = "summarizer_local_feature_not_compiled"
pub const HEADLESS_FEATURE_NOT_COMPILED: &'static str = "headless_feature_not_compiled"
pub const HEADLESS_RENDERER_UNAVAILABLE: &'static str = "headless_renderer_unavailable"
pub const HEADLESS_LAUNCH_FAILED: &'static str = "headless_launch_failed"
pub const HEADLESS_RENDER_TIMEOUT: &'static str = "headless_render_timeout"
pub const HEADLESS_PAGE_CLOSED: &'static str = "headless_page_closed"
pub const HEADLESS_INTERNAL_ERROR: &'static str = "headless_internal_error"
pub const CAPTIONER_NO_SUCH: &'static str = "captioner_no_such"
pub const CAPTIONER_NOT_CONFIGURED: &'static str = "captioner_not_configured"
pub const CAPTIONER_LOCAL_FEATURE_NOT_COMPILED: &'static str = "captioner_local_feature_not_compiled"
pub const CAPTIONER_RATE_LIMITED: &'static str = "captioner_rate_limited"
pub const CAPTIONER_AUTH_FAILED: &'static str = "captioner_auth_failed"
pub const CAPTIONER_BACKEND_UNAVAILABLE: &'static str = "captioner_backend_unavailable"
pub const CAPTIONER_MODEL_ERROR: &'static str = "captioner_model_error"
pub const CAPTIONER_IMAGE_DECODE_FAILED: &'static str = "captioner_image_decode_failed"
pub fn new(code: &'static str, message: impl Into<String>) -> Self
Trait Implementations§
Source§impl Clone for RoverError
impl Clone for RoverError
Source§fn clone(&self) -> RoverError
fn clone(&self) -> RoverError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RoverError
impl Debug for RoverError
Source§impl Deserialize<'static> for RoverError
impl Deserialize<'static> for RoverError
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'static>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'static>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for RoverError
impl RefUnwindSafe for RoverError
impl Send for RoverError
impl Sync for RoverError
impl Unpin for RoverError
impl UnsafeUnpin for RoverError
impl UnwindSafe for RoverError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more