Android Question SDK Manager: Update or Not Update?

Jorge M A

Well-Known Member
Licensed User
Hello everybody,

I'm doing a fresh installation of B4A (Free) on a new machine. I have followed the installation instructions step by step, even preserving the suggested folder names and locations.
So far so good.

My problem starts when I want to update the SDK using the B4A SDK Manager.
I get the following error:
Error: Warning: Could not create settings
java.lang.IllegalArgumentException
at com.android.sdklib.tool.sdkmanager.SdkManagerCliSettings.<init>(SdkManagerCliSettings.java:428)
at com.android.sdklib.tool.sdkmanager.SdkManagerCliSettings.createSettings(SdkManagerCliSettings.java:152)
at com.android.sdklib.tool.sdkmanager.SdkManagerCliSettings.createSettings(SdkManagerCliSettings.java:134)
at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:57)
at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:48)

Error: Warning: Could not create settings
java.lang.IllegalArgumentException
at com.android.sdklib.tool.sdkmanager.SdkManagerCliSettings.<init>(SdkManagerCliSettings.java:428)
at com.android.sdklib.tool.sdkmanager.SdkManagerCliSettings.createSettings(SdkManagerCliSettings.java:152)
at com.android.sdklib.tool.sdkmanager.SdkManagerCliSettings.createSettings(SdkManagerCliSettings.java:134)
at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:57)
at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:48)
Usage:
sdkmanager [--uninstall] [<common args>] [--package_file=<file>] [<packages>...]
sdkmanager --update [<common args>]
sdkmanager --list [<common args>]
sdkmanager --licenses [<common args>]
sdkmanager --version

With --install (optional), installs or updates packages.
By default, the listed packages are installed or (if already installed)
updated to the latest version.
With --uninstall, uninstall the listed packages.

<package> is a sdk-style path (e.g. "build-tools;23.0.0" or
"platforms;android-23").
<package-file> is a text file where each line is a sdk-style path
of a package to install or uninstall.
Multiple --package_file arguments may be specified in combination
with explicit paths.

With --update, all installed packages are updated to the latest version.

With --list, all installed and available packages are printed out.

With --licenses, show and offer the option to accept licenses for all
available packages that have not already been accepted.

With --version, prints the current version of sdkmanager.

Common Arguments:
--sdk_root=<sdkRootPath>: Use the specified SDK root instead of the SDK
containing this tool

--channel=<channelId>: Include packages in channels up to <channelId>.
Common channels are:
0 (Stable), 1 (Beta), 2 (Dev), and 3 (Canary).

--include_obsolete: With --list, show obsolete packages in the
package listing. With --update, update obsolete
packages as well as non-obsolete.

--no_https: Force all connections to use http rather than https.

--proxy=<http | socks>: Connect via a proxy of the given type.

--proxy_host=<IP or DNS address>: IP or DNS address of the proxy to use.

--proxy_port=<port #>: Proxy port to connect to.

--verbose: Enable verbose output.

* If the env var REPO_OS_OVERRIDE is set to "windows",
"macosx", or "linux", packages will be downloaded for that OS.
How can I solve it?
I have recently seen several posts that describe different problems when updating the SDK.

So, another question is is it worth doing the SDK update? When should it be done?
 

drgottjr

Expert
Licensed User
Longtime User
there are several recent posts in different threads about this. you can't use the latest sdk (¡no lo hagas!). you have to revert to the previous sdk.
go to the main b4x home page and use the new sdk download link erel changed yesterday. it redirects you to a previous version of the sdk (4333796), not the latest one. on the forum look for recent posts containing "SDK". you'll see what's going on. once you reload the old sdk, all is good.
 
Upvote 0

Jorge M A

Well-Known Member
Licensed User
Thank you.
For the first installation, it's perfect.
But my doubt remains open, what to do with the elements recommended by the Sdk Manager? Update or not?

1583260830917.png
 
Upvote 0

drgottjr

Expert
Licensed User
Longtime User
the error seems to be in the sdk itself. not the dependencies. i had to install some missing ones, and things seem ok. did you install the extras? if you created a new directory for the sdk to be safe, you may have forgotten the extras. they come after the link to download the sdk on b4x home.
 
Upvote 0

Jorge M A

Well-Known Member
Licensed User
Again, thank you @drgottjr

I don't seem to have made myself clear:
  • I don't have any mistakes yet.
  • I haven't compiled anything.
  • I'm setting up a new machine.
  • I followed the installation steps ok, and used the new (old) links from the Sdk.

Should I install the items recommended by the Sdk?
 
Upvote 0

drgottjr

Expert
Licensed User
Longtime User
yeah. it's what i had to do. when the new sdk caused the problems, i deleted everything and reinstalled b4a, the (old) sdk, the extras and when i ran the sdk, i had to installed all the maven items. everything works fine now. it's the equivaqlent of setting up a new machine.

i probably only had to reinstall the old sdk, but, at the time information was lacking, so redoing everything seemed like the safest way to proceed.
 
Upvote 0
Top