cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Grebnov (Akvelon)" <v-seg...@microsoft.com>
Subject RE: [DISCUSS] Cordova CLI error reporting
Date Wed, 11 Nov 2015 05:58:34 GMT
Cordova.raw which is used by CLI and other tools use promises which are rejected w/ CordovaError
[1] or just a string in case of error. So technically we support error codes but I don't think
we specify them in many places. 

As per particular error codes,, the following list could be a good start...

ToolExecutionError Android ADB or other tool failed
InvalidStateError The object is in an invalid state, for example working directory is not
a cordova directory, or something is corrupted (dependency plugin has been removed manually,
etc)
EncodingError  The encoding operation, being an encoding or a decoding one, failed, for example
we are unable to parse config.xml
NotSupportedError The operation is not supported (for example platform does not support this
method or parameter)
NetworkError A network error occurred.
TimeoutError The operation timed out.
AbortError The operation was aborted.
InvalidEnvironmentError We don't have some required tools installed (or similar)
NotFoundError The object can not be found here.

[1] https://github.com/apache/cordova-lib/blob/master/cordova-common/src/CordovaError/CordovaError.js#L37

Thx!
Sergey
-----Original Message-----
From: Dmitry Blotsky [mailto:dblotsky@microsoft.com] 
Sent: Wednesday, November 11, 2015 8:50 AM
To: <dev@cordova.apache.org> <dev@cordova.apache.org>
Subject: [DISCUSS] Cordova CLI error reporting

Hey folks,

Does the Cordova CLI have a meaningful status code and error description it returns when various
errors happen? Or do we only return 0/1 for success/failure and then just print out some hopefully
decipherable information on stderr?

I know we have some effort in improving logging in Cordova; is that effort addressing this?

Kindly,
Dmitry
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


Mime
View raw message