Skip to content

docs: Document span filtering migration to span first#5710

Closed
harryautomazione wants to merge 1 commit intogetsentry:masterfrom
harryautomazione:docs/ignore-spans
Closed

docs: Document span filtering migration to span first#5710
harryautomazione wants to merge 1 commit intogetsentry:masterfrom
harryautomazione:docs/ignore-spans

Conversation

@harryautomazione
Copy link

What

  • Adds documentation to MIGRATION_GUIDE.md explaining how to filter individual spans in the experimental "Span First" (streaming) mode.
  • Provides code examples for using the experimental ignore_spans configuration with String, Regex, and Dict rules.

Why

  • In transaction-based mode, spans are filtered in before_send_transaction.
  • In Span First mode, spans are streamed individually and bypass before_send_transaction.
  • Fixes Document span filtering migration #5363.

How

  • Added a section ## Migrating Span Filtering to Span First in MIGRATION_GUIDE.md.
  • Described the difference between modes and how _experiments={"ignore_spans": [...]} can be used.
  • Verified that rules (String, Regex, and Attributes) match internally using is_ignored_span().

Testing

  • Created a test script to verify is_ignored_span() behavior with multiple rule types (exact match, dictionary, attribute match).
  • Confirmed child spans inherit the parent's ignored state structure.

Risks / Impact

  • None, as it is documentation-only for an existing experimental config.

Checklist

  • Linked the relevant issue (Fixes Document span filtering migration #5363).
  • Described problem, solution and impact.
  • Added or updated tests where appropriate (Verified logic with scratchpad tests).
  • Verified no secrets or sensitive data are introduced.

@harryautomazione harryautomazione requested a review from a team as a code owner March 19, 2026 13:49
@github-actions
Copy link
Contributor

Semver Impact of This PR

🟢 Patch (bug fixes)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


New Features ✨

  • (logging) Separate ignore lists for events/breadcrumbs and sentry logs by sl0thentr0py in #5698

Bug Fixes 🐛

Anthropic

  • Set exception info on streaming span when applicable by alexander-alderman-webb in #5683
  • Patch AsyncStream.close() and AsyncMessageStream.close() to finish spans by alexander-alderman-webb in #5675
  • Patch Stream.close() and MessageStream.close() to finish spans by alexander-alderman-webb in #5674

Documentation 📚

  • Document span filtering migration to span first by harryautomazione in #5710
  • Add note on AI PRs to CONTRIBUTING.md by sentrivana in #5696

Internal Changes 🔧

  • Add -latest alias for each integration test suite by sentrivana in #5706
  • Use date-based branch names for toxgen PRs by sentrivana in #5704
  • 🤖 Update test matrix with new releases (03/19) by github-actions in #5703
  • Add client report tests for span streaming by sentrivana in #5677

Other

  • Update CHANGELOG.md by sentrivana in #5685

🤖 This preview updates automatically when you update the PR.

@sentrivana sentrivana closed this Mar 20, 2026
@harryautomazione
Copy link
Author

This Pull Request was a duplicate of work bundled elsewhere by mistake. Thank you to @sentrivana for closing it and keeping the board clean. Sorry for the noise!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Document span filtering migration

2 participants