From be7a28cb9badd9dd9a8f58824f3bfeb50b824b2e Mon Sep 17 00:00:00 2001 From: Anton Pirker Date: Wed, 20 Mar 2024 15:13:17 +0100 Subject: [PATCH] Updated migration guide --- MIGRATION_GUIDE.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/MIGRATION_GUIDE.md b/MIGRATION_GUIDE.md index f12bb38c88..e5019a7006 100644 --- a/MIGRATION_GUIDE.md +++ b/MIGRATION_GUIDE.md @@ -15,7 +15,11 @@ Looking to upgrade from Sentry SDK 1.x to 2.x? Here's a comprehensive list of wh - The `_ScopeManager` was moved from `sentry_sdk.hub` to `sentry_sdk.scope`. - Moved the contents of `tracing_utils_py3.py` to `tracing_utils.py`. The `start_child_span_decorator` is now in `sentry_sdk.tracing_utils`. - The actual implementation of `get_current_span` was moved to `sentry_sdk.tracing_utils`. `sentry_sdk.get_current_span` is still accessible as part of the top-level API. +- `sentry_sdk.tracing_utils.add_query_source()`: Removed the `hub` parameter. It is not necessary anymore. +- `sentry_sdk.tracing_utils.record_sql_queries()`: Removed the `hub` parameter. It is not necessary anymore. - `sentry_sdk.tracing_utils.get_current_span()` does now take a `scope` instead of a `hub` as parameter. +- `sentry_sdk.tracing_utils.should_propagate_trace()` now takes a `Client` instead of a `Hub` as first parameter. +- `sentry_sdk.utils.is_sentry_url()` now takes a `Client` instead of a `Hub` as first parameter. - `sentry_sdk.utils._get_contextvars` does not return a tuple with three values, but a tuple with two values. The `copy_context` was removed. - If you create a transaction manually and later mutate the transaction in a `configure_scope` block this does not work anymore. Here is a recipe on how to change your code to make it work: Your existing implementation: