[TIMOB-17731] Installation failed, longjohn.js 185 - has no method 'indexOf'
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2020-01-30T09:09:49.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 3.4.0 |
Components | Android |
Labels | 3.3.0.GA, TCSupport, android, installation, mobile |
Reporter | Gianpaolo |
Assignee | Chris Barber |
Created | 2014-07-22T09:30:10.000+0000 |
Updated | 2020-01-30T16:49:21.000+0000 |
Description
Hi,
when i try to build an application and launch it on the emulator, the console gives me this error:
[INFO] : Installing apk: /home/username/Documenti/Ti_Workspace/projectName/build/android/bin/projectName-dev-debug.apk
[ERROR] Application Installer abnormal process termination. Process exit value was 8
[TRACE] : Checking if package manager service is started
/usr/local/lib/node_modules/titanium/node_modules/longjohn/dist/longjohn.js:185
throw e;
^
has no method 'indexOf'
complete log here:
[Complete Log on PasteBin](http://pastebin.com/Q18pHFsA)
this is my complete environment:
[Complete Environment on PasteBin](http://pastebin.com/jyiAW5ZN)
have found a workaround... file: /home/user/.titanium/mobilesdk/linux/3.3.0.GA/android/cli/hooks/run.js from row 189 to 193 from this
to this
I have this same problem, using 3.3.0.GA, and latest Android SDK. It appears the issue is caused because the output variable from the 'ps' command is a javascript [object Object] rather than a string. A better workaround is to change line 198 to:
if (output.toString().indexOf('system_server') === -1) {
Hi, I have been recently faced by the same issue. "if (output.toString().indexOf('system_server') === -1) {" saved me !!!! Regards.
Thanks [~daorithos] for the report! [~ingo]: can you please assign Gianpaolo ([~daorithos]) as the Reporter? TIA!
Upon investigation, it seems the fix in the comments was put in place back in 3.4.0. https://github.com/appcelerator/titanium_mobile/pull/5915 Marking as fixed.
Fix verified in build: 9.0.0.v20200130071742. The fix that was put in place in 3.4.0 still exists today. Ticket closed.