I've added code to 'snapshot' span info including ID into a result object, and to trigger this whenever an error is raised in a callback, via the 'maybe_push_operr' function, here:
This sets the mres->errop value which is read when decoding an exception, here:
I've also set it to always snapshot span info to a result within get_common_objects, for good measure.
The info is provided as a 'tracing_output' attribute on the Result object, which is a list of spans. In the 'tags' field of each of these are listed an id and a child_of id.
These should correlate with the span IDs provided by the Threshold Logging Tracer.