开发者

Deploying Signed Application to Samsung Honeycomb tablet failing

All,

We have an application for Tablets that works fine when not deployed as a signed application. I can run the app from Eclipse to the Samsung tablet and everything works fine. Soon as I create a signed application I get the following error (stack trace at bottom):

Question: why is it doing this - I cannot make a signed app to give to others on my team to test - nor to the customer. It's driving me crazy - the Fragment that it says it can't find, is there - and note that I'm using the compatibility jar with a min sdk level of 10.

The error makes no sense - if the XML was at fault or the Fragment class didn't exist as it states, it could never run on my table from Eclipse in developer mode. I'm perplexed - and it's halted our development effort as a result...

Oh, just for the record:

Eclipse 3.6.2 Mac OS X 10.7 Lion Samsung Galaxy Tablet 10.1 with Android version 3.1

Any pointers would be greatly appreciated...

Here's the relevant part of the Manifest:

<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="com.twoguysmedia.puzzleSliderTab"
android:versionCode="2"
android:versionName="1.1.20"
android:installLocation="auto">
<uses-sdk
    android:minSdkVersion="4"
    android:targetSdkVersion="11" />

<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.CAMERA" />   
<uses-permission android:name="android.permission.GET_TASKS" />
<uses-permission android:name="android.permission.INTERNET" />    
<uses-permission android:name="android.permission.READ_PHONE_STATE" />    
<uses-permission android:name="android.permission.SET_WALLPAPER" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.SEND_SMS"/>

...

and here's the exception stack trace:

08-07 07:03:54.990: ERROR/AndroidRuntime(7937): FATAL EXCEPTION: main 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.twoguysmedia.puzzleSliderTab/com.twoguysmedia.puzzleSliderTab.PuzzleSliderTabListActivity}: android.view.InflateException: Binary XML file line #8: Error inflating class fragment 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1751) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1767) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.ActivityThread.access$1500(ActivityThread.java:122) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.ActivityThread$H.handl开发者_开发知识库eMessage(ActivityThread.java:1005) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.os.Handler.dispatchMessage(Handler.java:99) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.os.Looper.loop(Looper.java:132) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.ActivityThread.main(ActivityThread.java:4028) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at java.lang.reflect.Method.invokeNative(Native Method) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at java.lang.reflect.Method.invoke(Method.java:491) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:844) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:602) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at dalvik.system.NativeStart.main(Native Method) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): Caused by: android.view.InflateException: Binary XML file line #8: Error inflating class fragment 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:688) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.view.LayoutInflater.rInflate(LayoutInflater.java:724) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.view.LayoutInflater.inflate(LayoutInflater.java:479) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.view.LayoutInflater.inflate(LayoutInflater.java:391) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.view.LayoutInflater.inflate(LayoutInflater.java:347) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:242) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.Activity.setContentView(Activity.java:1780) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at com.twoguysmedia.puzzleSliderTab.PuzzleSliderTabListActivity.onCreate(Unknown Source) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1048) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1715) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): ... 11 more 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): Caused by: android.support.v4.app.o: Unable to instantiate fragment com.twoguysmedia.puzzleSliderTab.PuzzleSliderTabListFragment: make sure class name exists, is public, and has an empty constructor that is public 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.support.v4.app.u.a(Unknown Source) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.support.v4.app.u.a(Unknown Source) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.support.v4.app.FragmentActivity.onCreateView(Unknown Source) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:660) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): ... 20 more 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): Caused by: java.lang.ClassNotFoundException: com.twoguysmedia.puzzleSliderTab.PuzzleSliderTabListFragment in loader dalvik.system.PathClassLoader[/data/app/com.twoguysmedia.puzzleSliderTab-1.apk] 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:251) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at java.lang.ClassLoader.loadClass(ClassLoader.java:540) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): at java.lang.ClassLoader.loadClass(ClassLoader.java:500) 08-07 07:03:54.990: ERROR/AndroidRuntime(7937): ... 24 more 08-07 07:03:55.000: ERROR/android.os.Debug(286): Dumpstate > /data/log/dumpstate_app_error 08-07 07:03:55.000: WARN/ActivityManager(286): Force finishing activity com.twoguysmedia.puzzleSliderTab/.PuzzleSliderTabListActivity


For those who are wondering how this was solved - it turns out it's a minSDK issue - since the minimum SDK was less than the compiled SDK and the device was less than the compiled SDK, it allowed the app to be installed, but not run - thus the dump. The solution is to go back to the project and compile it at the level of the device to which it's being deployed - which kinda defeats the whole minSDK thing - wasn't that supposed to catch that problem?

Everything works fine now, anyway...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜