android
build_error
ai_generated
true
Failed to transform artifact 'support-v4.aar' using Jetifier. Reason: Cannot find a mapping for support class
ID: android/jetifier-transform-failed
82%Fix Rate
87%Confidence
3Evidence
2023-01-01First Seen
Version Compatibility
| Version | Status | Introduced | Deprecated | Notes |
|---|---|---|---|---|
| 8 | active | — | — | — |
Root Cause
Jetifier cannot convert a legacy Android Support Library artifact to AndroidX. Unmapped class or corrupt dependency.
genericWorkarounds
-
92% success Find and replace the old support-library dependency with its AndroidX equivalent
Replace 'com.android.support:support-v4:28.0.0' with 'androidx.legacy:legacy-support-v4:1.0.0'
-
88% success Run the AndroidX migration tool
Android Studio: Refactor > Migrate to AndroidX; updates imports and gradle dependencies automatically
-
80% success Exclude the problematic transitive dependency
implementation('com.example:lib:1.0') { exclude group: 'com.android.support', module: 'support-v4' }
Dead Ends
Common approaches that don't work:
-
Disable Jetifier (android.enableJetifier=false) without migrating
88% fail
Disabling Jetifier while support-library dependencies remain causes ClassNotFoundException at runtime.
-
Manually repackage the AAR file with AndroidX namespaces
85% fail
Fragile and error-prone. Updates to the library will require re-repackaging every time.