Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump sentry-sdk from 1.40.0 to 2.0.0 #48

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link

@dependabot dependabot bot commented on behalf of github Apr 25, 2024

Bumps sentry-sdk from 1.40.0 to 2.0.0.

Release notes

Sourced from sentry-sdk's releases.

2.0.0

This is the first major update in a long time!

We dropped support for some ancient languages and frameworks (Yes, Python 2.7 is no longer supported). Additionally we refactored a big part of the foundation of the SDK (how data inside the SDK is handled).

We hope you like it!

For a shorter version of what you need to do, to upgrade to Sentry SDK 2.0 see: https://docs.sentry.io/platforms/python/migration/1.x-to-2.x

New Features

  • Additional integrations will now be activated automatically if the SDK detects the respective package is installed: Ariadne, ARQ, asyncpg, Chalice, clickhouse-driver, GQL, Graphene, huey, Loguru, PyMongo, Quart, Starlite, Strawberry.
  • Added new API for custom instrumentation: new_scope, isolation_scope. See the Deprecated section to see how they map to the existing APIs.

Changed

(These changes are all backwards-incompatible. Breaking Change (if you are just skimming for that phrase))

  • The Pyramid integration will not capture errors that might happen in authenticated_userid() in a custom AuthenticationPolicy class.

  • The method need_code_loation of the MetricsAggregator was renamed to need_code_location.

  • The BackgroundWorker thread used to process events was renamed from raven-sentry.BackgroundWorker to sentry-sdk.BackgroundWorker.

  • The reraise function was moved from sentry_sdk._compat to sentry_sdk.utils.

  • 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:

    transaction = sentry_sdk.transaction(...)
    later in the code execution:
    with sentry_sdk.configure_scope() as scope:
    scope.set_transaction_name("new-transaction-name")

    needs to be changed to this:

    transaction = sentry_sdk.transaction(...)
    later in the code execution:
    scope = sentry_sdk.Scope.get_current_scope()
    scope.set_transaction_name("new-transaction-name")

... (truncated)

Changelog

Sourced from sentry-sdk's changelog.

2.0.0

This is the first major update in a long time!

We dropped support for some ancient languages and frameworks (Yes, Python 2.7 is no longer supported). Additionally we refactored a big part of the foundation of the SDK (how data inside the SDK is handled).

We hope you like it!

For a shorter version of what you need to do, to upgrade to Sentry SDK 2.0 see: https://docs.sentry.io/platforms/python/migration/1.x-to-2.x

New Features

  • Additional integrations will now be activated automatically if the SDK detects the respective package is installed: Ariadne, ARQ, asyncpg, Chalice, clickhouse-driver, GQL, Graphene, huey, Loguru, PyMongo, Quart, Starlite, Strawberry.
  • Added new API for custom instrumentation: new_scope, isolation_scope. See the Deprecated section to see how they map to the existing APIs.

Changed

(These changes are all backwards-incompatible. Breaking Change (if you are just skimming for that phrase))

  • The Pyramid integration will not capture errors that might happen in authenticated_userid() in a custom AuthenticationPolicy class.

  • The method need_code_loation of the MetricsAggregator was renamed to need_code_location.

  • The BackgroundWorker thread used to process events was renamed from raven-sentry.BackgroundWorker to sentry-sdk.BackgroundWorker.

  • The reraise function was moved from sentry_sdk._compat to sentry_sdk.utils.

  • 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:

    transaction = sentry_sdk.transaction(...)
    later in the code execution:
    with sentry_sdk.configure_scope() as scope:
    scope.set_transaction_name("new-transaction-name")

    needs to be changed to this:

    transaction = sentry_sdk.transaction(...)
    later in the code execution:
    scope = sentry_sdk.Scope.get_current_scope()
    scope.set_transaction_name("new-transaction-name")

... (truncated)

Commits
  • 38bbb8d Updated changelog
  • abca568 Updated changelog
  • 0b454c0 Updated changelog
  • 2642c8a Updated changelog
  • cc1dbc0 release: 2.0.0
  • 74310f0 Merge branch 'release/2.0.0rc6' into sentry-sdk-2.0
  • 62d4c48 release: 2.0.0rc6
  • 17715c0 Restore original behavior by always creating a span (#3005)
  • 7ef20df Merge baggage headers (incoming and new created ones) (#3001)
  • 9fc2f44 Fix duplicate baggage headers in Celery integration introduced in SDK 2.0 (#2...
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 1.40.0 to 2.0.0.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGELOG.md)
- [Commits](getsentry/sentry-python@1.40.0...2.0.0)

---
updated-dependencies:
- dependency-name: sentry-sdk
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file python Pull requests that update Python code labels Apr 25, 2024
@coveralls
Copy link

Pull Request Test Coverage Report for Build 8832805440

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 100.0%

Totals Coverage Status
Change from base Build 7819923251: 0.0%
Covered Lines: 19
Relevant Lines: 19

💛 - Coveralls

Copy link
Author

dependabot bot commented on behalf of github Apr 26, 2024

Superseded by #51.

@dependabot dependabot bot closed this Apr 26, 2024
@dependabot dependabot bot deleted the dependabot/pip/sentry-sdk-2.0.0 branch April 26, 2024 12:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file python Pull requests that update Python code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant