rust-minidump / minidump-writer

Rust rewrite of breakpad's minidump_writer
MIT License
68 stars 17 forks source link

Add soft errors to minidump #31

Open Jake-Shadle opened 2 years ago

Jake-Shadle commented 2 years ago

We've discussed loosening many of the hard failures inherited from Breakpad into more soft errors, as in many cases, even if a piece of process information cannot be retrieved for some reason, the dump will still contain all of the useful information that we did retrieve. For example, if we can't retrieve the name of a thread for some reason, or it isn't utf-8, that should just mean we skip that thread or write an empty or placeholder name for it, but don't fail the entire dump creation.

This however means that when you get a minidump it might be missing information you were expecting. What would be cool is if in these soft errors cases actually recorded the failure, eg "failed to get thread name for thread ", and actually add those failures to a separate minidump stream at the end. This would allow end users to still get the useful information that was retrieved during minidump creation, but also see exactly why there might be various things missing that they might have expected.

gabrielesvelto commented 1 year ago

Adding a datapoint here: most of the times we've seen Firefox fail to generate a minidump it's been for these three reasons (in order of volume):