Assertion failures seem to not generate an assertion failure message on Android
Categories
(Core :: XPCOM, defect)
Tracking
()
People
(Reporter: ehsan.akhgari, Unassigned)
References
Details
For example this failure appears like a crash on Android but the same one on Linux appears like an assertion failure
Comment 1•6 years ago
•
|
||
logcat has an assertion in it, but no stack:
08-07 20:29:08.573 11108 11123 F MOZ_Assert: Assertion failure: aWindow || aChannel, at /builds/worker/workspace/build/src/toolkit/components/antitracking/StorageAccess.cpp:288
I think the "problem" here is that we don't mix the test log with the output of logcat. The .extra
file does have a MozCrashReason=MOZ_ASSERT(aWindow || aChannel)
annotation at least, so maybe we can pull that out when we process the .dmp
.
I'm inclined to move this to testing as this is more of a test harness issue, but I suppose it could be a mfbt
issue. It looks like we don't actually support dumping the stack in MOZ_ReportAssertionFailure on android.
ehsan, what behavior do you actually want here? Is having the assertion in logcat good enough?
Reporter | ||
Comment 2•6 years ago
|
||
Oh, interesting!
I think dumping this to logcat is probably a good idea, but I would really expect to see this message next to where the stack appears (which is stderr, right?) to be able to identify an assertion failure when looking at a log quickly.
Comment 3•6 years ago
|
||
(In reply to :Ehsan Akhgari from comment #2)
Oh, interesting!
I think dumping this to logcat is probably a good idea, but I would really expect to see this message next to where the stack appears (which is stderr, right?) to be able to identify an assertion failure when looking at a log quickly.
The stack in the test log that treeherder is parsing comes from mozcrash
and is generated with minidump_stackwalk
after the process crashes due to the assertion, it has no idea that there was an assertion at all. I think we have two issues here:
- It would be nice if treeherder could tell us this was a failed assertion rather than a crash. I think we'd need to modify mozcrash so that it parses annotations for that to happen.
- It would be nice if we dumped the stack in logcat on android as well. This would be an xpcom change to make a version of
WalkTheStack
that uses a writer function rather than a file stream. We'd need to update mfbt to use this function as well.
Reporter | ||
Comment 4•6 years ago
|
||
Thanks, that all makes sense!
Updated•3 years ago
|
Description
•