Fixed
Status Update
Comments
ap...@google.com <ap...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-master-dev
commit 164bb50bcabe96a05e80c2d9ce03533e1dc6d26e
Author: Ian Lake <ilake@google.com>
Date: Mon Oct 14 11:03:23 2019
Fix FragmentContainerView inflation with obfuscation
Instead of using a literal for the class name, using
FragmentContainerView.class.getName() to support
obfuscation via ProGuard.
Test: ran testapp with obfuscation
Fixes: 142657034
Change-Id: I9ae40ddb5d3308790d6963f09f3eb110837dbb4c
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentLayoutInflaterFactory.java
https://android-review.googlesource.com/1142236
https://goto.google.com/android-sha1/164bb50bcabe96a05e80c2d9ce03533e1dc6d26e
Branch: androidx-master-dev
commit 164bb50bcabe96a05e80c2d9ce03533e1dc6d26e
Author: Ian Lake <ilake@google.com>
Date: Mon Oct 14 11:03:23 2019
Fix FragmentContainerView inflation with obfuscation
Instead of using a literal for the class name, using
FragmentContainerView.class.getName() to support
obfuscation via ProGuard.
Test: ran testapp with obfuscation
Fixes: 142657034
Change-Id: I9ae40ddb5d3308790d6963f09f3eb110837dbb4c
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentLayoutInflaterFactory.java
Description
Version used: 1.2.0-beta02
Seems that the FragmentLayoutInflaterFactory that is supposed to handle FragmentContainerView isn't being invoked when using obfuscated class name.
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.twofortyfouram.locale.x/com.twofortyfouram.locale.x.Qs}: android.view.InflateException: Binary XML file line #0: Binary XML file line #0: Error inflating class com.twofortyfouram.locale.x.ıſ
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2793)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2864)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1567)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:156)
at android.app.ActivityThread.main(ActivityThread.java:6524)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:941)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:831)
Caused by: android.view.InflateException: Binary XML file line #0: Binary XML file line #0: Error inflating class com.twofortyfouram.locale.x.ıſ
Caused by: android.view.InflateException: Binary XML file line #0: Error inflating class com.twofortyfouram.locale.x.ıſ
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.newInstance0(Constructor.java)
at java.lang.reflect.Constructor.newInstance(Constructor.java:430)
at android.view.LayoutInflater.createView(LayoutInflater.java:656)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:798)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:738)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:869)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:832)
at android.view.LayoutInflater.inflate(LayoutInflater.java:518)
at android.view.LayoutInflater.inflate(LayoutInflater.java:426)
at android.view.LayoutInflater.inflate(LayoutInflater.java:377)
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:555)
at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161)
at androidx.activity.ComponentActivity.onCreate(ComponentActivity.java:158)
at androidx.fragment.app.FragmentActivity.onCreate(FragmentActivity.java:312)
at androidx.appcompat.app.AppCompatActivity.onCreate(AppCompatActivity.java:106)
at com.twofortyfouram.ui.screen.consent.activity.ConsentActivity.onCreate(ConsentActivity.java:56)
at android.app.Activity.performCreate(Activity.java:6910)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1123)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2746)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2864)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1567)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:156)
at android.app.ActivityThread.main(ActivityThread.java:6524)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:941)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:831)
Caused by: java.lang.UnsupportedOperationException: FragmentContainerView must be within a FragmentActivity to be instantiated from XML.
at androidx.fragment.app.FragmentContainerView.<init>(FragmentContainerView.java:124)
at androidx.fragment.app.FragmentContainerView.<init>(FragmentContainerView.java:124)
at androidx.fragment.app.FragmentContainerView.<init>(FragmentContainerView.java:124)