Hmm. Attaching user-level data has definitely been an ask.
the existing callbacks system is in the process of getting replaced by the instrumentation system.
What I had in mind for this was instead some context manager usage
with dispatcher.instrument({"trace_id": "123"}):
query_engine.query()
But, not quite there yet, probably this week π
I don't think I would accept that PR though π
Since it only covers two entry points, and modifies a core interface. Feels like a better solution would be just keep it all contained to the callback (or, instrumenation)