Closed ZacSweers closed 2 years ago
@ZacSweers is the only connection between this consumer and the swipe refresh layout library that the library has a public attr
type named "swipeRefreshLayoutProgressSpinnerBackgroundColor" and the consumer defines a value for an item with that same name? In other words, is this just a matter of string matching?
I should note that the plugin already understands that the library defines this attr. In other contexts, it can already detect that this attr is used by a consumer. It's a peculariaty of the custom matching algorithm that it currently misses this usage. So what I'm after is a deeper understanding of how to do this matching to accurately detect more usages. (see link for kdoc explaining current algo.)
Build scan link
Plugin version
1.1.0
Gradle version
7.4.2
(Optional) Android Gradle Plugin (AGP) version
7.1.3
Describe the bug
Consider this styleable declaration from androidx.swiperefreshlayout
https://cs.android.com/androidx/platform/frameworks/support/+/androidx-main:swiperefreshlayout/swiperefreshlayout/src/main/res-public/values/attrs.xml;l=19
I found a case where a library depends on this library and defines a value for this attribute like so
DAGP misses this usage and removes the library as unused
To Reproduce Steps to reproduce the behavior: See above
Expected behavior
I'd expect it to properly detect this
Additional context