cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <>
Subject [jira] [Commented] (CB-12640) listing targets with cli scripts does not work with v26 of android sdk tools
Date Mon, 10 Apr 2017 19:24:41 GMT


ASF subversion and git services commented on CB-12640:

Commit e13e15d3e9aa4b9a61c6ece434e7c023fa5c3553 in cordova-android's branch refs/heads/master
from filmaj
[;h=e13e15d ]

CB-12640: better handling of unrecognized commands on windows. removed error checking in emulator
image listing when shelling out, as we already defensively dont shell out if the program is
not on the PATH / not recognized. added additional test for windows unrecognized command errors
for target listing. fixed up spying in a test.

> listing targets with cli scripts does not work with v26 of android sdk tools
> ----------------------------------------------------------------------------
>                 Key: CB-12640
>                 URL:
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Android
>    Affects Versions: 6.2.1
>            Reporter: Filip Maj
>            Assignee: Filip Maj
> Another Android SDK Tools release, another new problem! The {{android}} command is back
and has completely different behaviour from SDK Tools 25.3.x. It now:
>   a) prints out a deprecation warning
>   b) does not accept {{list targets}} (must be {{list target}}) as a command
>   c) does not print out an error message telling users to use {{avdmanager}} or {{sdkmanager}}
> In 25.3.x, {{android}} would exit with a non-zero exit code and print out an error message
saying the command is no longer available.
> In 25.2.x and below, {{android}} was the go-to command for all things android-related.
> The [existing code for listing targets|]
currently follows this flow:
> 1. Run {{android}} to list targets. If that works, parse targets out and exit.
> 2. If {{android}} fails with a non-zero exit code and a particular error message (the
one that would be output in 25.3.x version of the tools), leverage {{sdkmanager}}, parse its
output for installed targets.
> [~bowserj] brought up a good point to just use {{avdmanager list target}} instead of
{{sdkmanager}} - it maintains the same output format for target listing as the old {{android}}
tool does, which should allow us to remove the [code we have in place to convert {{sdkmanager}}
output to the old {{android}} output format|].

> Another solid [~bowserj] piece of advice is to try to use the {{avdmanager}} tool first
before falling back to {{android}}.
> I will attempt to implement both suggestions above, and add test cases leveraging output
fixtures from the various Android SDK Tool versions.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message