Commit 30862fc
fix(compose): add isImportantForBounds() to SentryTagModifierNode for compose-ui 1.11+ (#5672)
* fix(compose): add isImportantForBounds() to SentryTagModifierNode for compose-ui 1.11+
compose-ui 1.11 added SemanticsModifierNode.isImportantForBounds() as an
abstract method. SentryTagModifierNode was compiled against compose-ui 1.6.x,
where the method does not exist, so its bytecode lacks an implementation.
When an accessibility client (TalkBack, UiAutomator, adb uiautomator dump)
traverses the Compose semantics tree at runtime on 1.11+, the JVM cannot find
the method and throws AbstractMethodError.
Adding fun isImportantForBounds(): Boolean = false without the override keyword
(since the method is absent from the 1.6.x compile-time dependency) places the
method in the class bytecode. The JVM satisfies the abstract method requirement
via signature matching at runtime. SentryTagModifierNode stores only a semantic
tag with no layout/visual effect, so false is the correct return value.
* fix formatting
* chore(changelog): Add Changelog entry
---------
Co-authored-by: Markus Hintersteiner <markus.hintersteiner@sentry.io>1 parent 0980ed7 commit 30862fc
2 files changed
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
Lines changed: 10 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
56 | 66 | | |
57 | 67 | | |
0 commit comments