chore(compose): Update SentryTraced to emit a span only for initial composition - #6051
Merged
Merged
Conversation
0xadam-brown
force-pushed
the
fix/sentry-traced-one-composition-span
branch
from
September 3, 2026 10:44
0f87b22 to
8b70bf7
Compare
📲 Install BuildsAndroid
|
0xadam-brown
force-pushed
the
fix/sentry-traced-one-composition-span
branch
from
September 3, 2026 10:54
8b70bf7 to
e048a34
Compare
0xadam-brown
commented
Sep 3, 2026
0xadam-brown
force-pushed
the
fix/sentry-traced-one-composition-span
branch
from
September 3, 2026 11:19
e048a34 to
a110425
Compare
0xadam-brown
marked this pull request as ready for review
September 3, 2026 11:20
0xadam-brown
requested review from
adinauer,
markushi,
romtsn and
runningcode
as code owners
September 3, 2026 11:20
0xadam-brown
commented
Sep 3, 2026
…omposition Commit updates SentryTraced to: - emit a span only for initial composition, rather than for every composition of the wrapped composable; and - add an origin to ui.render spans, just like we already do for composition spans. Commit also cleans up use of ImmutableHolder and renames it to MutableRef.
0xadam-brown
force-pushed
the
fix/sentry-traced-one-composition-span
branch
from
September 3, 2026 12:05
277216f to
b9706dc
Compare
runningcode
approved these changes
Sep 3, 2026
runningcode
left a comment
Contributor
There was a problem hiding this comment.
I'll give it a 👍 with the caveat that I'm not a compose expert.
0xadam-brown
enabled auto-merge (squash)
September 3, 2026 18:28
0xadam-brown
disabled auto-merge
September 3, 2026 18:42
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.
📜 Description
PR updates SentryTraced to:
ui.renderspans, just like we already do for composition spans.I've also cleaned up use of ImmutableHolder and renamed it to MutableRef in response to @runningcode's reasonable thoughts here.
💡 Motivation and Context
These are behavior changes to follow the fixes in #6049.
💚 How did you test it?
I had my clanker exercise SentryTraced composables in our sample app and verify the output.
📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps
Fix the currently broken CompositionLocals that lead to the possibility of a stale parent transaction.