We are readying an update to our app, which was last published on 3.2.3 using the Alloy framework. We are able to compile without any error using the new 3.5.1 sdk, but the app crashes on launch. We are getting the following error:
[ERROR] : TiApplication: (main) [1546,1889] Sending event: exception on thread: main msg:java.lang.RuntimeException: Unable to start activity ComponentInfo{com.thewolverine.android/org.appcelerator.titanium.TiActivity}: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.; Titanium 3.5.1,2015/03/05 10:08,96875c9 [ERROR] : TiApplication: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.thewolverine.android/org.appcelerator.titanium.TiActivity}: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity. [ERROR] : TiApplication: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2211) [ERROR] : TiApplication: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2261) [ERROR] : TiApplication: at android.app.ActivityThread.access$600(ActivityThread.java:141) [ERROR] : TiApplication: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1256) [ERROR] : TiApplication: at android.os.Handler.dispatchMessage(Handler.java:99) [ERROR] : TiApplication: at android.os.Looper.loop(Looper.java:137) [ERROR] : TiApplication: at android.app.ActivityThread.main(ActivityThread.java:5103) [ERROR] : TiApplication: at java.lang.reflect.Method.invokeNative(Native Method) [ERROR] : TiApplication: at java.lang.reflect.Method.invoke(Method.java:525) [ERROR] : TiApplication: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:737) [ERROR] : TiApplication: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553) [ERROR] : TiApplication: at dalvik.system.NativeStart.main(Native Method) [ERROR] : TiApplication: Caused by: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity. [ERROR] : TiApplication: at android.support.v7.app.ActionBarActivityDelegate.onCreate(ActionBarActivityDelegate.java:108) [ERROR] : TiApplication: at android.support.v7.app.ActionBarActivityDelegateICS.onCreate(ActionBarActivityDelegateICS.java:57) [ERROR] : TiApplication: at android.support.v7.app.ActionBarActivity.onCreate(ActionBarActivity.java:98) [ERROR] : TiApplication: at org.appcelerator.titanium.TiBaseActivity.onCreate(TiBaseActivity.java:525) [ERROR] : TiApplication: at org.appcelerator.titanium.TiActivity.onCreate(TiActivity.java:18) [ERROR] : TiApplication: at android.app.Activity.performCreate(Activity.java:5133) [ERROR] : TiApplication: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087) [ERROR] : TiApplication: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2175) [ERROR] : TiApplication: ... 11 more [INFO] : Process: Sending signal. PID: 5301 SIG: 9We have tried several different solutions, including adding a theme to our tiapp.xml as follows:
<android xmlns:android="http://schemas.android.com/apk/res/android"> <manifest android:versionCode="104" android:versionName="1.0.4"> <application android:theme="@style/Theme.AppCompat.Light"/> <supports-screens android:anyDensity="false"/> </manifest> </android>This doesn't seem to fix the issue as it did for others. Is there anything else we should look at or try?