Hi Daniel,I'm sorry that our crash reporting documentation is not really up-to-date. We've been doing some very large refactoring and the docs didn't catch up, it's one of my goals to improve them this year.
In the meantime the easiest way to check if your crash annotation is present is the following:
- Add the annotation to `toolkit/crashreporter/CrashAnnotations.yaml`- Build with `ac_add_options --enable-crashreporter` in your .mozconfig (which you already did) - Run with `./mach run --enable-crash-reporter` (notice the different dash compared to the mozconfig, sorry about that, historic artifact) - Crash the process you care about: you can use about:crashparent for the parent process, about:crashcontent for content processes, ... If the process doesn't have code dedicated to make it crash you can always crash it via `kill -ABRT <pid>` on Linux and macOS. This will trigger the crash reporter - At this stage you'll be able to submit the crash but I don't recommend it as Socorro won't show you new annotations by default unless you have protected data access. Instead, before interacting with the crash reporter dialog look for the crash report files. They'll be under `~/.mozilla/firefox/Crash Reports/pending` on Linux, `%UserProfile%/AppData/Roaming/Mozilla/Firefox/Crash Reports/pending/` on Windows and `~/Library/Application Support/Mozilla/Firefox/Crash Reports/pending` on macOS). Each crash report is made of two files <uuid>.dmp and <uuid>.extra. The .extra file is JSON and will contain the annotations.
If for some reason you still need to submit the crashes then it's a better idea to use Socorro staging environment. Go to about:config and change the `breakpad.reportURL` pref from `https://crash-stats.mozilla.org/report/index/` to `https://crash-stats.allizom.org/report/index/`.
Gabriele On 06/03/24 04:52, Daniel Holbert wrote:
Thanks! To clarify, I'm not talking about writing automated tests - just how I might manually spot-testing that an intentional crash in the appropriate spot (in my own local build) does indeed include annotations that I added nearby.Right now I'm stuck at the "how do I get the crash reporter to show up" phase, which is maybe easy to address, but I'm also curious if this is the right sort of thing to do in the first place vs. if there are easier/recommended ways to preview the annotations that have been recorded.On Tue, Mar 5, 2024, 7:09 PM Nick Alexander <[email protected] <mailto:[email protected]>> wrote:Hi Daniel, others, On Tue, Mar 5, 2024 at 4:14 PM Daniel Holbert <[email protected] <mailto:[email protected]>> wrote: Thanks Gabriele-- this seems great for making crash reports more useful! Can you provide guidance (or link to documentation) for how to locally test a newly added annotation, to be sure it's working properly? i.e. once I've added an annotation, how might I go about generating a dummy crash report so that I can make sure my annotation shows up? It's not particularly easy, but it's also not particularly hard, to verify that crashes are collected (for example, https://bugzilla.mozilla.org/show_bug.cgi?id=1679440 <https://bugzilla.mozilla.org/show_bug.cgi?id=1679440>) and that annotations are correct (e.g., https://bugzilla.mozilla.org/show_bug.cgi?id=1697875 <https://bugzilla.mozilla.org/show_bug.cgi?id=1697875>). I do recall that it was not worth the hassle to locate the tests next to the tested feature; it was much easier to put them next to the existing crash tests. I will also caution that even once the annotations are in place, it requires additional work to make them useful: e.g., something like https://bugzilla.mozilla.org/show_bug.cgi?id=1796132 <https://bugzilla.mozilla.org/show_bug.cgi?id=1796132> is required. Hopefully others will tell me that this dance is simpler now :) Best, Nick
-- You received this message because you are subscribed to the Google Groups "[email protected]" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/a/mozilla.org/d/msgid/dev-platform/2775a958-1bb7-4e7c-8b58-b3d27a0c50a4%40mozilla.com.
OpenPGP_signature.asc
Description: OpenPGP digital signature
