Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-17182] Android: App built with latest 3.3.0 sdk fails to install on android 2.3.X device/emulator

GitHub Issuen/a
TypeBug
PriorityCritical
StatusClosed
ResolutionFixed
Resolution Date2014-06-20T17:39:23.000+0000
Affected Version/sRelease 3.3.0
Fix Version/sRelease 3.3.0, Release 3.4.0
ComponentsAndroid
Labelsmodule_build, qe-3.3.0, qe-testadded
ReporterLokesh Choudhary
AssigneeChris Barber
Created2014-06-18T21:54:26.000+0000
Updated2014-07-07T18:51:35.000+0000

Description

This is a regression. Works as expected with 3.2.3.GA

Description:

1. Create a default app in studio. 2. Build it to an android 2.3.X device with the latest 3.3.0 sdk or the one mentioned in the environment.

Actual Result:

1. The app fails to install on the device/emulator, with the error below: Console Logs:
[ERROR] :  Failed to install apk on "YT9003XD4W"
[ERROR] Application Installer abnormal process termination. Process exit value was 143
[ERROR] Application Installer abnormal process termination. Process exit value was 143
Studio Logs:
!ENTRY com.appcelerator.titanium.android.core 4 0 2014-06-18 14:22:39.636
!MESSAGE (Build 3.3.0.201406171619) [ERROR]  Exit value not available until process terminates.
!STACK 1
org.eclipse.debug.core.DebugException: Exit value not available until process terminates.
	at org.eclipse.debug.core.model.RuntimeProcess.getExitValue(RuntimeProcess.java:372)
	at com.appcelerator.titanium.android.internal.ui.DebugLaunchStatusHandler.handleStatus(DebugLaunchStatusHandler.java:31)
	at com.appcelerator.titanium.android.core.launching.AndroidInstallerLaunchConfigurationDelegate.cleanUp(AndroidInstallerLaunchConfigurationDelegate.java:122)
	at com.appcelerator.titanium.android.core.launching.AndroidInstallerLaunchConfigurationDelegate.access$0(AndroidInstallerLaunchConfigurationDelegate.java:103)
	at com.appcelerator.titanium.android.core.launching.AndroidInstallerLaunchConfigurationDelegate$TitaniumDeployListener.error(AndroidInstallerLaunchConfigurationDelegate.java:91)
	at com.appcelerator.titanium.core.internal.cli.TitaniumDeployManager.fireError(TitaniumDeployManager.java:67)
	at com.appcelerator.titanium.core.internal.cli.TitaniumDeployManager.fireError(TitaniumDeployManager.java:59)
	at com.appcelerator.titanium.android.core.launching.AndroidInstallAppStreamListener.streamAppended(AndroidInstallAppStreamListener.java:85)
	at org.eclipse.debug.internal.core.OutputStreamMonitor$ContentNotifier.run(OutputStreamMonitor.java:258)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
	at org.eclipse.debug.internal.core.OutputStreamMonitor$ContentNotifier.notifyAppend(OutputStreamMonitor.java:268)
	at org.eclipse.debug.internal.core.OutputStreamMonitor.fireStreamAppended(OutputStreamMonitor.java:117)
	at org.eclipse.debug.internal.core.OutputStreamMonitor.read(OutputStreamMonitor.java:157)
	at org.eclipse.debug.internal.core.OutputStreamMonitor.access$1(OutputStreamMonitor.java:135)
	at org.eclipse.debug.internal.core.OutputStreamMonitor$1.run(OutputStreamMonitor.java:208)
	at java.lang.Thread.run(Thread.java:695)
!SUBENTRY 1 org.eclipse.debug.core 4 5010 2014-06-18 14:22:39.637
!MESSAGE Exit value not available until process terminates.

!ENTRY org.eclipse.debug.ui 4 120 2014-06-18 14:22:40.140
!MESSAGE Error logged from Debug UI: 
!STACK 0
java.io.IOException
	at org.eclipse.debug.internal.core.StreamsProxy.write(StreamsProxy.java:129)
	at org.eclipse.debug.internal.ui.views.console.ProcessConsole$InputReadJob.run(ProcessConsole.java:687)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)

Expected Result:

1. The app should install & launch successfully on an android 2.3.X device/emulator.

Comments

  1. Ingo Muschenetz 2014-06-18

    Are we sure this isn't related to https://developer.appcelerator.com/question/160535/process-exit-value-was-143-after-upgrading-to-sdk-32x or http://developer.appcelerator.com/question/162845/error-application-installer-abnormal-process-termination-process-exit-value-was-143?
  2. Lokesh Choudhary 2014-06-18

    Packaging the app & installing through adb gives :
     Failure [INSTALL_FAILED_OLDER_SDK]
  3. Chris Barber 2014-06-19

    Master pull request: https://github.com/appcelerator/titanium_mobile/pull/5824 3_3_X pull request: https://github.com/appcelerator/titanium_mobile/pull/5825 To test (the easy way), build the default 2 tab app for Android and open the generated build/android/AndroidManifest.xml and notice that the minSdkVersion is 10 after this PR (14 before). You should also add a Android manifest section to the tiapp.xml and test various min and target SDK versions and make sure the warnings and errors make sense when you specify versions too low, target < min, and when the target api level is not installed:
       <android>
           <manifest>
               <uses-sdk android:minSdkVersion="10" android:targetSdkVersion="14" android:maxSdkVersion="19"/>
           </manifest>
       </android>
       
  4. Ingo Muschenetz 2014-06-19

    I see [~hpham] as reviewer, great. I want to make sure he is okay with this change.
  5. Chris Barber 2014-06-20

    Made a few verbiage changes: Master pull request: https://github.com/appcelerator/titanium_mobile/pull/5826 3_3_X pull request: https://github.com/appcelerator/titanium_mobile/pull/5827
  6. Tim Poulsen 2014-06-20

    Generates AndroidManifest as expected. Messages output when minSdkVersion or targetSdkVersion are set too low are clear and helpful.
  7. Lokesh Choudhary 2014-06-24

    Verified the fix. Apps built with latest 3.3.0 sdk install & run successfully on android device/emulator 2.3.X. Closing. Environment: Appc Studio : 3.3.0.201406231625 Ti SDK : 3.3.0.v20140624130120 Mac OSX : 10.8.5 Alloy : 1.4.0-rc2 CLI - 3.3.0-rc2 Code Processor: 1.1.1 Sony Xperia: 2.3.7

JSON Source