#[non_exhaustive]pub struct CrashError {
pub timestamp: SystemTime,
pub code: Option<i32>,
pub signal: Option<i32>,
pub stdout: Txt,
pub stderr: Txt,
pub args: Box<[Txt]>,
pub minidump: Option<PathBuf>,
pub os: Txt,
}Expand description
Info about an app-process crash.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.timestamp: SystemTimeCrash moment.
code: Option<i32>Process exit code.
signal: Option<i32>Unix signal that terminated the process.
stdout: TxtFull capture of the app stdout.
stderr: TxtFull capture of the app stderr.
args: Box<[Txt]>Arguments used.
minidump: Option<PathBuf>Minidump file.
os: TxtOperating system.
See std::env::consts::OS for details.
Implementations§
Source§impl CrashError
impl CrashError
Sourcepub fn is_stdout_plain(&self) -> bool
pub fn is_stdout_plain(&self) -> bool
Gets if stdout does not contain any ANSI scape sequences.
Sourcepub fn is_stderr_plain(&self) -> bool
pub fn is_stderr_plain(&self) -> bool
Gets if stderr does not contain any ANSI scape sequences.
Sourcepub fn stdout_plain(&self) -> Txt
pub fn stdout_plain(&self) -> Txt
Get stdout without any ANSI escape sequences (CSI).
Sourcepub fn stderr_plain(&self) -> Txt
pub fn stderr_plain(&self) -> Txt
Get stderr without any ANSI escape sequences (CSI).
Sourcepub fn has_panic_widget(&self) -> bool
pub fn has_panic_widget(&self) -> bool
Gets if stderr contains a crash panic that traced widget/window path.
Sourcepub fn find_panic(&self) -> Option<CrashPanic>
pub fn find_panic(&self) -> Option<CrashPanic>
Try parse stderr for the crash panic.
Only reliably works if the panic fully printed correctly and was formatted by the panic
hook installed by crash_handler or by the display print of CrashPanic.
Trait Implementations§
Source§impl Clone for CrashError
impl Clone for CrashError
Source§fn clone(&self) -> CrashError
fn clone(&self) -> CrashError
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CrashError
impl Debug for CrashError
Source§impl<'de> Deserialize<'de> for CrashError
impl<'de> Deserialize<'de> for CrashError
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<CrashError, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<CrashError, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl Display for CrashError
Alternate mode {:#} prints plain stdout and stderr (no ANSI escape sequences).
impl Display for CrashError
Alternate mode {:#} prints plain stdout and stderr (no ANSI escape sequences).
Source§impl Serialize for CrashError
impl Serialize for CrashError
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Auto Trait Implementations§
impl Freeze for CrashError
impl RefUnwindSafe for CrashError
impl Send for CrashError
impl Sync for CrashError
impl Unpin for CrashError
impl UnsafeUnpin for CrashError
impl UnwindSafe for CrashError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DataNoteValue for T
impl<T> DataNoteValue for T
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
Source§impl<T> FsChangeNote for T
impl<T> FsChangeNote for T
§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>
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>
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>
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