Skip to content

ref: Move sampler out of integrations/opentelemetry/ #4258

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

Merged
merged 3 commits into from
Apr 10, 2025

Conversation

sentrivana
Copy link
Contributor

@sentrivana sentrivana commented Apr 9, 2025

Moving stuff out of integrations/opentelemetry/ step by step since there is no OpenTelemetry integration anymore -- it's part of the core SDK.

This moves sentry_sdk/integrations/opentelemetry/sampler.py -> sentry_sdk/opentelemetry/sampler.py

References #3853

Copy link

codecov bot commented Apr 9, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 83.60%. Comparing base (c425533) to head (38f6886).
Report is 1 commits behind head on potel-base.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@             Coverage Diff             @@
##           potel-base    #4258   +/-   ##
===========================================
  Coverage       83.59%   83.60%           
===========================================
  Files             144      145    +1     
  Lines           14660    14662    +2     
  Branches         2324     2324           
===========================================
+ Hits            12255    12258    +3     
  Misses           1687     1687           
+ Partials          718      717    -1     
Files with missing lines Coverage Δ
...ntry_sdk/integrations/opentelemetry/integration.py 89.74% <100.00%> (ø)
...y_sdk/integrations/opentelemetry/span_processor.py 81.81% <100.00%> (ø)
sentry_sdk/opentelemetry/__init__.py 100.00% <100.00%> (ø)
sentry_sdk/opentelemetry/sampler.py 91.40% <ø> (ø)

... and 3 files with indirect coverage changes

@sentrivana sentrivana marked this pull request as ready for review April 9, 2025 11:03
@sentrivana sentrivana requested a review from a team as a code owner April 9, 2025 11:03
@sentrivana sentrivana changed the title ref: Move sampler out of integrations/opentelemetry ref: Move sampler out of integrations/opentelemetry/ Apr 9, 2025
@szokeasaurusrex
Copy link
Member

@sentrivana actually I have a question about this PR (and the related ones depending on it): It looks like you are moving all of these files directly under sentry_sdk. Would it perhaps make more sense to put them under sentry_sdk/tracing, or perhaps a new directory (like sentry_sdk/spans)?

I think keeping them in the same directory might make sense, since this Otel-span stuff is all still closely related to each other

@sentrivana
Copy link
Contributor Author

Changed the new location to sentry_sdk/opentelemetry/sampler.py and exposed the Sampler in sentry_sdk/opentelemetry/__init__.py for convenience

@sentrivana sentrivana merged commit 32369cb into potel-base Apr 10, 2025
126 of 127 checks passed
@sentrivana sentrivana deleted the ivana/move-sampler-from-integration branch April 10, 2025 10:02
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.

2 participants