Skip to content

Comments

chore: Refactor SentryAttributes into a separate class#4936

Open
jamescrosswell wants to merge 3 commits intomainfrom
sentry-attributes
Open

chore: Refactor SentryAttributes into a separate class#4936
jamescrosswell wants to merge 3 commits intomainfrom
sentry-attributes

Conversation

@jamescrosswell
Copy link
Collaborator

Before closing #4912 I figured we could extract some of the refactorings that might be useful in other PRs dealing with Attributes. Basically there's some functionality that is only accessible in the SentryMetrics class at the moment, but which will be needed by any other classes that also have Attributes.

#skip-changelog

@github-actions
Copy link
Contributor

github-actions bot commented Feb 19, 2026

Semver Impact of This PR

None (no version bump detected)

📋 Changelog Preview

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


This PR will not appear in the changelog.


🤖 This preview updates automatically when you update the PR.

@jamescrosswell jamescrosswell changed the title Refactored SentryAttributes into a separate class chore: Refactor SentryAttributes into a separate class Feb 19, 2026
@codecov
Copy link

codecov bot commented Feb 19, 2026

Codecov Report

❌ Patch coverage is 70.90909% with 16 lines in your changes missing coverage. Please review.
✅ Project coverage is 73.87%. Comparing base (f201b65) to head (e67baee).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
src/Sentry/Protocol/SentryAttributes.cs 68.08% 13 Missing and 2 partials ⚠️
src/Sentry/SentryMetric.Factory.cs 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4936      +/-   ##
==========================================
- Coverage   73.90%   73.87%   -0.03%     
==========================================
  Files         496      497       +1     
  Lines       17951    17960       +9     
  Branches     3516     3516              
==========================================
+ Hits        13266    13268       +2     
- Misses       3824     3831       +7     
  Partials      861      861              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jamescrosswell jamescrosswell marked this pull request as ready for review February 20, 2026 04:39
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

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