Skip to content

Support sentry-sdk 3.x once 3.0 is GA #380

Open

Description

@lesnik512

Blocked until sentry-sdk 3.0 is released as GA. 3.0.0b2 (2026-10-27) is the latest release on PyPI today, and the 3.0 release notes plan GA for November 2026.

#359 added support for 3.x alongside 2.x and tested it against 3.0.0b2. #379 removed that support, so lite-bootstrap 2.0 can ship before GA with sentry-sdk>=2.70,<3. The betas were still changing: b2 kept trace_lifecycle, which b1's migration guide listed as removed, and it removed enable_metrics, stream_gen_ai_spans and trace_ignore_status_codes. This issue brings 3.x support back against the GA release. It doesn't break 2.x users, so it can ship in a 2.x minor.

Work

  • Start from Cap sentry-sdk below 3 and remove the 3.x code paths #379's diff, which records every 3.x path that was removed. Then check each one against the GA migration guide rather than restoring it blindly:
    • LoggingIntegration: on 3.x, level means Sentry Logs and event_level defaults to None. feat(sentry)!: support sentry-sdk 3 alongside 2.x and raise the floor to 2.70 #359 built breadcrumb_level=sentry_logging_breadcrumb_level, event_level=logging.ERROR, level=None on 3.x.
    • ignore_logger now silences Sentry Logs only, and its 2.x meaning moved to ignore_logger_for_events. Litestar's lean capture calls it for "litestar".
    • event_from_exception took no client_options on 3.0.0b2.
    • LoggingIntegration is no longer a default integration on 3.x. lite-bootstrap appends its own while sentry_default_integrations is True.
    • Options 3.0 removes raise TypeError("Unknown option ...") at sentry_sdk.init. Recheck the final list, and check DEFAULT_DATA_COLLECTION against GA's data_collection keys.
  • Test first: run the suite against the GA release and record what fails.
  • pyproject.toml: sentry-sdk>=2.70,<4, and rewrite the comment above it.
  • CI: bring back a job that runs the suite on sentry-sdk<3, because the pytest jobs will resolve 3.x once it is GA. Pin the other leg to the GA version, or let it resolve the newest 3.x.
  • Benchmarks: make micro.py, repro_sentry_txn.py and sentry_scenarios.py run on both majors again, as feat(sentry)!: support sentry-sdk 3 alongside 2.x and raise the floor to 2.70 #359 did. On 3.x, no transaction is built while tracing is off.
  • Docs: restore the per-major LoggingIntegration call and the note on removed options in configuration.md. Remeasure the Sentry cost tables in fastapi.md, litestar.md and fastmcp.md on GA, and add a 3.x column.

Verify: the suite passes on the newest 2.x and on the 3.0 GA release, and ty check passes against both.

Activity

  1. added
    enhancementNew feature or request
    blockedWaiting on an external dependency or upstream change
    on Oct 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    blockedWaiting on an external dependency or upstream changeenhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions