sentry-python icon indicating copy to clipboard operation
sentry-python copied to clipboard

Hubs & Scopes missing tasks

Open antonpirker opened this issue 1 year ago • 2 comments

  • [x] Make sure each start_span always forks the current scope.
  • [x] Make sure active span is always on the current scope. (this includes also cleaning up our messy code that saves the span to the scope)
  • [ ] Store isolation and current scope in an "execution_context" ContextVar

antonpirker avatar Feb 20 '24 15:02 antonpirker

Hey there. Are you actively working on this? If so, do you have any estimation on when it will be ready?

This issue would help me greatly if done, as it will make adding tags to scopes in asyncio code work well, instead of overriding tags between different tasks in the ioloop since sentry is not ioloop-aware while contextvars is.

Thanks!

hxyannay avatar Feb 25 '24 14:02 hxyannay

Hey @hxyannay, an initial version of the scopes refactoring is already available in version 2.0.0a1 -- if you feel like trying it out and giving us feedback that would be much appreciated! Just note that it's an alpha release, so not production ready and there might be issues -- if you encounter any please let us know.

The final stable release is planned for a couple weeks from now, depending on how the alpha/release candidate does internally and among folks who want to try it out.

sentrivana avatar Feb 27 '24 13:02 sentrivana

We are past this now.

Please have a look at the issues labeled SDK 2.0 to see what is still missing for 2.0: https://github.com/getsentry/sentry-python/issues?q=is%3Aissue+is%3Aopen+label%3A%22SDK+2.0%22

antonpirker avatar Mar 15 '24 13:03 antonpirker