Next Python SDK major - #5005
Draft
sentrivana wants to merge 54 commits into
Draft
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #5005 +/- ##
===========================================
+ Coverage 70.55% 83.76% +13.21%
===========================================
Files 180 180
Lines 18077 18080 +3
Branches 3008 3009 +1
===========================================
+ Hits 12754 15145 +2391
+ Misses 4432 1943 -2489
- Partials 891 992 +101
|
Closed
Contributor
Codecov Results 📊✅ 94094 passed | ⏭️ 5209 skipped | Total: 99303 | Pass Rate: 94.75% | Execution Time: 327m 41s 📊 Comparison with Base Branch
➖ Removed Tests (1)View removed tests
All tests are passing successfully. ✅ Patch coverage is 91.69%. Project has 2284 uncovered lines. Files with missing lines (11)
Coverage diff@@ Coverage Diff @@
## main #PR +/-##
==========================================
+ Coverage 90.00% 90.32% +0.32%
==========================================
Files 193 185 -8
Lines 24946 23593 -1353
Branches 9000 8552 -448
==========================================
+ Hits 22451 21309 -1142
- Misses 2495 2284 -211
- Partials 1435 1379 -56Generated by Codecov Action |
Contributor
Semver Impact of This PR⚪ None (no version bump detected) 📋 Changelog PreviewThis is how your changes will appear in the changelog. New Features ✨
Bug Fixes 🐛Anthropic
Documentation 📚
Internal Changes 🔧
Other
🤖 This preview updates automatically when you update the PR. |
Add `UnraisablehookIntegration` to the default integrations list.
Stop raising exceptions `from None` in the ASGI and asyncio integrations. Closes #5624
Remove everything hub related, including all sorts of compatibility shims around hubs/scopes. Also remove deprecated session methods. `configure_scope` and `push_scope` removal coming in a future PR. #### Issues Closes #5001
The integration requires additional configuration which should be intentional on the user's part. #### Issues Closes #4993
- Remove everything in `integrations/opentelemetry` (`SentrySpanProcessor`, `SentryPropagator`, etc.) - Remove associated test files and CI config - Move old propagator functions and consts that we were using in `OTLPIntegration` to the OTLP propagator directly - Remove `instrumenter` Note: `NoOpSpan` was not removed because it makes mypy blow up. Not worth the effort as we'll anyway get rid of it when dropping transaction based tracing. #### Issues Closes #6932
### Description The API is deprecated and slated for removal in 3.0. #### Issues Closes #5019 #### Reminders - Please add tests to validate your changes, and lint your code using `uv run ruff`. - Add GH Issue ID _&_ Linear ID (if applicable) - PR title should use [conventional commit](https://develop.sentry.dev/engineering-practices/commit-messages/#type) style (`feat:`, `fix:`, `ref:`, `meta:`) - For external contributors: [CONTRIBUTING.md](https://github.com/getsentry/sentry-python/blob/master/CONTRIBUTING.md), [Sentry SDK development docs](https://develop.sentry.dev/sdk/), [Discord community](https://discord.gg/Ww9hbqr)
### Description Remove the deprecated API. #### Issues Closes #5018
### Description Most of the entries in our extras list serve as a way to communicate/enforce the lower boundary of the respective framework that we support. This creates a parallel system to the version checks we already have in each integration. Some extras, however, define extra dependencies or specific extras that are required for an integration to work correctly (e.g. the Flask integration needs `blinker` to work properly). In that case, keep the extra. #### Issues Closes #6259
- Add `_check_minimum_version` calls to all integrations that had entries in `_MIN_VERSIONS` but were not enforcing them at runtime - Add new `_MIN_VERSIONS` entries for integrations that were missing them - Use package-provided version if possible; fallback to `package_version` only if not available
### Description The LaunchDarkly client is a [singleton](https://launchdarkly.com/docs/sdk/server-side/python#initialize-the-client). As such, it doesn't make sense to provide a way to patch a specific client only. This allows us to get rid of the integation `__init__`, which is always good: integrations are meant to be setup via `setup_once`. #### Issues Closes #7040 #### Reminders - Please add tests to validate your changes, and lint your code using `uv run ruff`. - Add GH Issue ID _&_ Linear ID (if applicable) - PR title should use [conventional commit](https://develop.sentry.dev/engineering-practices/commit-messages/#type) style (`feat:`, `fix:`, `ref:`, `meta:`) - For external contributors: [CONTRIBUTING.md](https://github.com/getsentry/sentry-python/blob/master/CONTRIBUTING.md), [Sentry SDK development docs](https://develop.sentry.dev/sdk/), [Discord community](https://discord.gg/Ww9hbqr)
- drop old chalice from ci - bump min version in `integrations/__init__.py`
We're now enforcing Tornado > 6, so compat code for older versions is not needed anymore
Fixes for things that the bots [surfaced](#5005) on the major branch: - some version checks were too late (after patching) - fix TrytondWSGI integration name/`_MIN_VERSIONS` entry mismatch Also, changed the warning of the `DidNotEnable` message from "X not installed" to "X not installed or incompatible".
Strawberry is not auto-enabling in 3.0 anymore, so this guard is not necessary.
### Description Remove the `@ai_track` decorator and associated tests #### Issues Part of #6894
### Description The actual compat code was removed with the contextvars shim. Just test utils remain. #### Issues Closes #4997
Drop support for redis-py<[4.2](https://pypi.org/project/redis/4.2.0/): - remove redis cluster legacy (it was moved directly into redis-py in 4.1) - remove deprecated `max_data_size` integration option - remove conditional patching of async client and pipeline -- just patch always (they're available from 4.2+) - use the Redis class instead of StrictRedis (which is just an alias)
### Description - drop experimental options if they have a top-level replacement - remove `start_profile_session` and `stop_profile_session` (replaced by `start_profile` and `stop_profile`) There is a `continuous_profiling_auto_start` experimental option without a top-level replacement. There's also a `try_autostart_continuous_profiler` function that says it should be deprecated in favor of "auto lifecycle". There is no auto lifecycle as far as I can tell. Or is this referring to `lifecycle=trace`? Leaving this as is for now... #### Issues Closes #6946
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We're preparing our next major on this branch.
The project is tracked in Linear. If you don't have access, we'll try to tag issues belonging to the project with the
SDK3.0 label on GitHub so that you can follow along.Context
You might have read this announcement about us discontinuing work on a 3.0. This is referring to the work done on the
potel-basebranch, which included two types of changes: a huge refactor of our tracing code on the one hand, and various unrelated changes, improvements and fixes on the other. We're dropping the huge refactor part, and only porting the rest, to a new branch and eventually a new 3.0 release.Changes