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§
§timestamp: SystemTime
Crash moment.
code: Option<i32>
Process exit code.
signal: Option<i32>
Unix signal that terminated the process.
stdout: Txt
Full capture of the app stdout.
stderr: Txt
Full capture of the app stderr.
args: Box<[Txt]>
Arguments used.
minidump: Option<PathBuf>
Minidump file.
os: Txt
Operating 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
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 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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)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
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> 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>
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