pub enum BrowserError {
LaunchFailed {
reason: String,
},
CdpError {
operation: String,
message: String,
},
PoolExhausted {
active: usize,
max: usize,
},
Timeout {
operation: String,
duration_ms: u64,
},
NavigationFailed {
url: String,
reason: String,
},
ScriptExecutionFailed {
script: String,
reason: String,
},
ConnectionError {
url: String,
reason: String,
},
ConfigError(String),
Io(Error),
}Expand description
Errors that can occur during browser automation.
Every variant carries enough structured context to decide on a retry policy or surface a useful diagnostic message without string-parsing.
Variants§
LaunchFailed
Browser process failed to start.
CdpError
Chrome DevTools Protocol (CDP) operation failed.
Fields
PoolExhausted
All pool slots are occupied and the wait timeout elapsed.
Timeout
An operation exceeded its configured timeout.
Fields
Page navigation failed.
ScriptExecutionFailed
JavaScript evaluation failed.
ConnectionError
WebSocket / transport connection error.
ConfigError(String)
Invalid configuration value.
Io(Error)
Underlying I/O error.
Trait Implementations§
Source§impl Debug for BrowserError
impl Debug for BrowserError
Source§impl Display for BrowserError
impl Display for BrowserError
Source§impl Error for BrowserError
impl Error for BrowserError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<CdpError> for BrowserError
impl From<CdpError> for BrowserError
Auto Trait Implementations§
impl Freeze for BrowserError
impl !RefUnwindSafe for BrowserError
impl Send for BrowserError
impl Sync for BrowserError
impl Unpin for BrowserError
impl !UnwindSafe for BrowserError
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.