natchez icon indicating copy to clipboard operation
natchez copied to clipboard

Do not activate span since thread-local propagation does not work correctly when using cats-effect

Open mwisnicki opened this issue 6 months ago • 2 comments

As mentioned in https://github.com/typelevel/natchez/pull/1186#issuecomment-3020004700 we should not be activating spans on thread local by default. This is incorrect when using IO.

The only safe way to do this is explicitly as in https://github.com/typelevel/natchez/pull/1189.

Not activating spans is also consistent with other backends like OpenTelemetry.

mwisnicki avatar Jun 30 '25 17:06 mwisnicki

Any chance of getting this merged?

mwisnicki avatar Dec 01 '25 04:12 mwisnicki

Perhaps if it's a Span.Options parameter? It'd also have to be ported to other backends. I think it's OK to roll with it as long as it's opt-in.

kubukoz avatar Dec 01 '25 17:12 kubukoz