sentry-android-gradle-plugin icon indicating copy to clipboard operation
sentry-android-gradle-plugin copied to clipboard

Improve automatic tagging of Composables

Open romtsn opened this issue 1 year ago • 1 comments

Description

Currently our automatic tagging through the compiler plugin is suboptimal, because we're using a Composable name for SentryTag which can be default composable names like Image/Text/Slider etc. and which don't uniquely identify the composable.

We could use filename + function name + lineno to uniquely identify composables and make the ViewHierarchies and Transactions better represent what components are being traced.

Prior art: https://github.com/VKCOM/vkompose/blob/master/compiler-plugin/compose-test-tag/applier/plugin/src/main/kotlin/com/vk/compiler/plugin/compose/test/tag/applier/TestTagApplier.kt

romtsn avatar Mar 21 '25 11:03 romtsn

Let's have an opt-in flag in the beginning and add some tracking around it so we have an idea how widely adopted this is.

romtsn avatar Mar 26 '25 13:03 romtsn