Jenny Gee created CB-9007:
-----------------------------
Summary: main run loop for cordova-cli can hit error handler with
empty error, which isn't logged
Key: CB-9007
URL: https://issues.apache.org/jira/browse/CB-9007
Project: Apache Cordova
Issue Type: Bug
Components: CordovaLib, iOS
Affects Versions: 5.0.0
Environment: OS X 10.10, cordova-ios added to project, ios-deploy
version 1.3.2
Reporter: Jenny Gee
Priority: Critical
iPhone 5 running iOS 8.3 connected via lightning cable to MBP
{quote}
$ /Users/jgee/REPOS/SCW/web-app/platforms/ios/cordova/run --device
{quote}
actual results:
no output.
with debugging, we see:
{{get_ios_deploy_version}}'s ({{versions.js}}) child process error callback is
called with:
{code}
error = { [Error: Command failed: ] killed: false, code: 253, signal: null }
stderr = ""
stdout = "1.3.2"
{code}
The root cause for this is:
{quote}
$ ios-deploy --version ; echo $?
1.3.2
253
{quote}
expected results:
1. when the main run path in cordova-cli runs:
{code}
if (['--help', '/?', '-h', 'help', '-help', '/help'].indexOf(args[2]) > -1) {
run.help();
} else {
run.run(args).done(function() {
console.log('** RUN SUCCEEDED **');
}, function (err) {
var errorMessage = (err && err.stack) ? err.stack : err;
console.error(errorMessage);
process.exit(2);
});
}
{code}
the err handler case needs to complain loudly and clearly if it manages to be
called with an empty error, as here.
2. {{versions.js}} {{get_ios_deploy_version}} exec handler should perhaps
handle the case where it gets stdout of a nice version number but for whatever
reason the app exits with code {{253}} instead of {{0}}.
3. {{ios-deploy}} should really not return exit code {{253}} when it's able to
spit out a version number.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]