Search Unity

  1. If you have experience with import & exporting custom (.unitypackage) packages, please help complete a survey (open until May 15, 2024).
    Dismiss Notice
  2. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice

Bug CommandInvokationFailure: Failed to update Android SDK package list.

Discussion in 'Android' started by milox777, Jan 12, 2024.

  1. milox777

    milox777

    Joined:
    Sep 23, 2012
    Posts:
    195
    Just updated to 2021.3.34f1. Using all default Unity supplied SDKs.

    Code (CSharp):
    1. Unable to list target platforms. Please make sure the android sdk path is correct.
    2. Error: Could not find or load main class Files\Unity\Hub\Editor\2021.3.34f1\Editor\Data\PlaybackEngines\AndroidPlayer\SDK\cmdline-tools\2.1\bin\\..
    3. Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
    4.  
    5. UnityEditor.Android.CommandInvokationFailure: Unable to list target platforms. Please make sure the android sdk path is correct.
    6. C:\Program Files\Unity\Hub\Editor\2021.3.34f1\Editor\Data\PlaybackEngines\AndroidPlayer\SDK\cmdline-tools\2.1\bin\avdmanager.bat list target -c
     
    pandolfini likes this.
  2. Neozman

    Neozman

    Joined:
    Sep 29, 2016
    Posts:
    67
    We struggling with the same problem
     
    pandolfini and anycolourulike like this.
  3. milox777

    milox777

    Joined:
    Sep 23, 2012
    Posts:
    195
    I downgraded to 2021.3.33f1 and it works again
     
  4. Neozman

    Neozman

    Joined:
    Sep 29, 2016
    Posts:
    67
    I need play core libs update unfortunatly bcz i ma trying to fix PAD problems(
     
  5. mrphilipjoel

    mrphilipjoel

    Joined:
    Jul 6, 2019
    Posts:
    61
    We just updated, and have the same issue.
     
  6. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    Could you attach editor.log?
     
  7. Masashi-Wada

    Masashi-Wada

    Joined:
    Jul 6, 2010
    Posts:
    89
    I have the same problem. While it worked on 2021.3.32, I encountered errors when upgrading to 2021.3.34(Windows10).
    However, I found that this issue only occurs when the Unity Editor is installed in the "Program Files" directory. In my case, changing the Hub settings to install it to "C:\Unity\Editor" resolved the problem. As long as I reinstall into the "Program Files" folder, I saw the error messages.
    The log when the error occurred is as follows:

    CommandInvokationFailure: Failed to update Android SDK package list.
    C:\Program Files\Unity\Hub\Editor\2021.3.34f1\Editor\Data\PlaybackEngines\AndroidPlayer\SDK\cmdline-tools\2.1\bin\sdkmanager.bat --list

    Environment Variables:
    PROCESSOR_ARCHITECTURE = AMD64
    JAVA_HOME = C:\Program Files\Unity\Hub\Editor\2021.3.34f1\Editor\Data\PlaybackEngines\AndroidPlayer\OpenJDK

    (skip)

    stderr[
    エラー: メイン・クラスFiles\Unity\Hub\Editor\2021.3.34f1\Editor\Data\PlaybackEngines\AndroidPlayer\SDK\cmdline-tools\2.1\bin\\..が見つからなかったかロードできませんでした
    Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
    ]
    stdout[

    ]
    exit code: 1
    UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <2c344dfa67884d4ca623f814e4a08809>:0)
    UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <2c344dfa67884d4ca623f814e4a08809>:0)
    UnityEditor.Android.AndroidSDKTools.RunAndroidSdkTool (System.String toolName, System.String arguments, System.Boolean updateCommand, System.String errorMsg, System.String toolsDir, System.String[] warningsToIgnore) (at <2c344dfa67884d4ca623f814e4a08809>:0)
    UnityEditor.Android.AndroidSDKTools.ListComponentsVersions () (at <2c344dfa67884d4ca623f814e4a08809>:0)
    UnityEditor.Android.SDKManager.UpdatePackagesList () (at <2c344dfa67884d4ca623f814e4a08809>:0)
    UnityEditor.Android.SDKManager.ListAvailable (UnityEditor.Android.SDKManager+Component type) (at <2c344dfa67884d4ca623f814e4a08809>:0)
    UnityEditor.Android.PlayerSettingsEditorExtension+<>c__DisplayClass127_0.<StartGettingReleasedAPILevels>b__0 () (at <2c344dfa67884d4ca623f814e4a08809>:0)
    System.Threading.ThreadHelper.ThreadStart_Context (System.Object state) (at <7e05db41a20b45108859fa03b97088d4>:0)
    System.Threading.ExecutionContext.RunInternal (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) (at <7e05db41a20b45108859fa03b97088d4>:0)
    System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) (at <7e05db41a20b45108859fa03b97088d4>:0)
    System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state) (at <7e05db41a20b45108859fa03b97088d4>:0)
    System.Threading.ThreadHelper.ThreadStart () (at <7e05db41a20b45108859fa03b97088d4>:0)
    UnityEngine.<>c:<RegisterUECatcher>b__0_0(Object, UnhandledExceptionEventArgs)
     
    milox777 likes this.
  8. Neozman

    Neozman

    Joined:
    Sep 29, 2016
    Posts:
    67
    Last edited: Jan 15, 2024
    byserhatt likes this.
  9. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    Hey, it seems there's a bug in Google's Android SDK:

    Workaround 1:
    Patch Editor\Data\PlaybackEngines\AndroidPlayer\SDK\cmdline-tools\2.1\bin\sdkmanager.bat

    Change
    Code (CSharp):
    1. set DEFAULT_JVM_OPTS=-Dcom.android.sdklib.toolsdir=%~dp0\..
    to

    Code (CSharp):
    1. set DEFAULT_JVM_OPTS="-Dcom.android.sdklib.toolsdir=%~dp0\.."
    Workaround 2:
    * Remove Editor\Data\PlaybackEngines\AndroidPlayer\SDK\cmdline-tools

    Workaround 3:
    P.S Unity 2022.2 and up uses cmdline-tools 6.0, where this bug was fixed by Google.
     
    Last edited: Mar 7, 2024
  10. FloBeber

    FloBeber

    Joined:
    Jun 9, 2015
    Posts:
    166
    This solution works. Thank you so much for your help on this!
     
    Strom_CL and victoref like this.
  11. hitoriiichan

    hitoriiichan

    Joined:
    Oct 26, 2020
    Posts:
    2
    Thank you so much for your help! I tried this and works.
     
  12. TSUKASA88

    TSUKASA88

    Joined:
    Feb 1, 2024
    Posts:
    1
    Works like a charm thank you!
     
  13. YousafGrewal

    YousafGrewal

    Joined:
    Jul 5, 2018
    Posts:
    30
    What's the problem with unity .I think unity team didn't bother to test their products.
    upload_2024-2-3_23-45-0.png
     

    Attached Files:

    omermursel441 likes this.
  14. Mythique

    Mythique

    Joined:
    Oct 18, 2015
    Posts:
    19
    The workaround is all right. But it's sad to see it wasn't fixed in 2021.3.35f1.
     
  15. MidnightGameDeveloper

    MidnightGameDeveloper

    Joined:
    Apr 26, 2014
    Posts:
    123
    The workaround doesn't work on macOS.
     
    pandolfini likes this.
  16. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    Can you share Editor.log with error?
     
  17. MidnightGameDeveloper

    MidnightGameDeveloper

    Joined:
    Apr 26, 2014
    Posts:
    123
    This is from my Editor.log file:
    Code (CSharp):
    1. .....
    2. CommandInvokationFailure: Failed to update Android SDK package list.
    3. /Applications/Unity Editor/2021.3.34f1/PlaybackEngines/AndroidPlayer/SDK/cmdline-tools/2.1/bin/sdkmanager --list
    4.  
    5. Environment Variables:
    6. DEBUG_ENV_VAR = UnityHub
    7. XPC_FLAGS = 0x0
    8. __CFBundleIdentifier = com.unity3d.unityhub
    9. ...
    10. COMMAND_MODE = unix2003
    11. ...
    12. JAVA_TOOL_OPTIONS = -Dfile.encoding=UTF-8
    13. JAVA_HOME = /Applications/Unity Editor/2021.3.34f1/PlaybackEngines/AndroidPlayer/OpenJDK
    14. ...
    15. USER =
    16. MallocNanoZone = 0
    17. LOGNAME =
    18. __CF_USER_TEXT_ENCODING = 0x1F5:0x0:0x3
    19. ...
    20. PATH = /usr/bin:/bin:/usr/sbin:/sbin
    21. SSH_AUTH_SOCK = /private/tmp/com.apple.launchd.sH5x6TCdTe/Listeners
    22. ...
    23. HOME = /Users/
    24. TMPDIR = /var/folders/dr/q5910vpn30b8dw4vr7f8zkj40000gn/T/
    25. ORIGINAL_XDG_CURRENT_DESKTOP = undefined
    26. ...
    27. SHELL = /bin/zsh
    28. ...
    29.  
    30. stderr[
    31. Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
    32. Fehler: Hauptklasse Editor.2021.3.34f1.PlaybackEngines.AndroidPlayer.SDK.cmdline-tools.2.1 konnte nicht gefunden oder geladen werden
    33. ]
    34. stdout[
    35.  
    36. ]
    37. exit code: 1
    38.   at UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) [0x00033] in <2c344dfa67884d4ca623f814e4a08809>:0
    39.   at UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) [0x0002d] in <2c344dfa67884d4ca623f814e4a08809>:0
    40.   at UnityEditor.Android.AndroidSDKTools.RunAndroidSdkTool (System.String toolName, System.String arguments, System.Boolean updateCommand, System.String errorMsg, System.String toolsDir, System.String[] warningsToIgnore) [0x00096] in <2c344dfa67884d4ca623f814e4a08809>:0
    41.   at UnityEditor.Android.AndroidSDKTools.ListComponentsVersions () [0x00086] in <2c344dfa67884d4ca623f814e4a08809>:0
    42.   at UnityEditor.Android.SDKManager.UpdatePackagesList () [0x00079] in <2c344dfa67884d4ca623f814e4a08809>:0
    43.   at UnityEditor.Android.SDKManager.HighestVersionInstalled (UnityEditor.Android.SDKManager+Component tool) [0x00001] in <2c344dfa67884d4ca623f814e4a08809>:0
    44.   at UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKToolsDetector.GetVersion () [0x00006] in <2c344dfa67884d4ca623f814e4a08809>:0
    45.   at UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector.Detect (System.Version minVersion, UnityEditor.Android.PostProcessor.ProgressHandler onProgress) [0x0002b] in <2c344dfa67884d4ca623f814e4a08809>:0
    46.   at UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.EnsureSDKComponentVersion (System.Version minVersion, UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector detector) [0x00007] in <2c344dfa67884d4ca623f814e4a08809>:0
    47.   at UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context) [0x00172] in <2c344dfa67884d4ca623f814e4a08809>:0
    48.   at UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) [0x00078] in <2c344dfa67884d4ca623f814e4a08809>:0
    49. UnityEditor.BuildPipeline:BuildPlayerInternalNoCheck(String[], String, String, BuildTargetGroup, BuildTarget, Int32, BuildOptions, String[], Boolean)
    50. UnityEditor.DefaultBuildMethods:BuildPlayer(BuildPlayerOptions) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs:170)
    51. UnityEditor.BuildPlayerWindow:CallBuildMethods(Boolean, BuildOptions) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs:95)
    52. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun(Boolean) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindow.cs:187)
    53. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun() (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindow.cs:181)
    54.  
    55. (Filename: /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindow.cs Line: 181)
    56.  
    57. Unloading 34 Unused Serialized files (Serialized files now loaded: 0)
    58. Unloading 42 unused Assets / (52.5 KB). Loaded Objects now: 7162.
    59. Memory consumption went from 168.1 MB to 168.1 MB.
    60. Total: 41.610017 ms (FindLiveObjects: 0.600219 ms CreateObjectMapping: 0.535009 ms MarkObjects: 40.243026 ms  DeleteObjects: 0.230719 ms)
    61.  
    62. Build Finished, Result: Failure.
    63. Unloading 0 Unused Serialized files (Serialized files now loaded: 0)
    64. Loaded scene 'Temp/__Backupscenes/0.backup'
    65.     Deserialize:            8.101 ms
    66.     Integration:            248.908 ms
    67.     Integration of assets:  0.008 ms
    68.     Thread Wait Time:       0.024 ms
    69.     Total Operation Time:   257.040 ms
    70. Unloading 0 unused Assets / (0.9 MB). Loaded Objects now: 7090.
    71. Memory consumption went from 166.3 MB to 165.4 MB.
    72. Total: 31.580643 ms (FindLiveObjects: 0.587648 ms CreateObjectMapping: 0.413192 ms MarkObjects: 30.441520 ms  DeleteObjects: 0.137280 ms)
    73.  
    74. Build completed with a result of 'Failed' in 3 seconds (2608 ms)
    75. UnityEngine.StackTraceUtility:ExtractStackTrace () (at /Users/bokken/build/output/unity/unity/Runtime/Export/Scripting/StackTrace.cs:37)
    76. UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[])
    77. UnityEngine.Logger:Log (UnityEngine.LogType,object)
    78. UnityEngine.Debug:LogError (object)
    79. UnityEditor.BuildPlayerWindow/DefaultBuildMethods:BuildPlayer (UnityEditor.BuildPlayerOptions) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs:193)
    80. UnityEditor.BuildPlayerWindow:CallBuildMethods (bool,UnityEditor.BuildOptions) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs:95)
    81. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun (bool) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindow.cs:187)
    82. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun () (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindow.cs:181)
    83.  
    84. (Filename: /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs Line: 193)
    85.  
    86. UnityEditor.BuildPlayerWindow+BuildMethodException: 3 errors
    87.   at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002ce] in /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs:194
    88.   at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs:95
    89. UnityEngine.StackTraceUtility:ExtractStackTrace () (at /Users/bokken/build/output/unity/unity/Runtime/Export/Scripting/StackTrace.cs:37)
    90. UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[])
    91. UnityEngine.Logger:Log (UnityEngine.LogType,object)
    92. UnityEngine.Debug:LogError (object)
    93. UnityEditor.BuildPlayerWindow:CallBuildMethods (bool,UnityEditor.BuildOptions) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs:100)
    94. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun (bool) (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindow.cs:187)
    95. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun () (at /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindow.cs:181)
    96.  
    97. (Filename: /Users/bokken/build/output/unity/unity/Editor/Mono/BuildPlayerWindowBuildMethods.cs Line: 100)
    98.  
    99. 2024-02-08 19:00:14.547 Unity[2576:99736] NSEventModifierFlagFunction specified to -setKeyEquivalentModifierMask: for item <NSMenuItem: 0x7fa9d9255dc0 UI Toolkit Debugger, ke='Command-F5'>, but is only supported for system-provided menu items; will not be used
    100. .....
     
  18. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    Do you get the same error with Unity 2022.3, it uses cmd-linetools 6.0, wondering if Google fixed this issue there ?
     
  19. MidnightGameDeveloper

    MidnightGameDeveloper

    Joined:
    Apr 26, 2014
    Posts:
    123
    Yes, same issue in 2022.3.14f1 except it says : Editor.2022.3.14f1.PlaybackEngines.AndroidPlayer.SDK.cmdline-tools.6.0 not found
     
  20. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    I guess your only option for now - is to install Unity to path without spaces, or move Android SDK to path without spaces.
     
    weto4ka, avataris-io and pandolfini like this.
  21. MidnightGameDeveloper

    MidnightGameDeveloper

    Joined:
    Apr 26, 2014
    Posts:
    123
    I will install 2021.3.32f1 (which worked fine) and set the path in the preferences of the new version.
     
  22. _geo__

    _geo__

    Joined:
    Feb 26, 2014
    Posts:
    1,352
    Thank you for the patch tutorial on the .bat file. That works (on Windows).

    Yes, that may be the issue yet I'd like to ask why this was not flagged by Unity's QA? This should have been an easy failure on any kind of automated test: Does it build if the Android SDK is installed via the HUB or not.

    I don't mean this as a rant. I am actually interested in how something like this could pass Unity's release tests. Is the SDK download not fixed to a certain version for each release?
     
    Last edited: Feb 29, 2024
  23. pandolfini

    pandolfini

    Joined:
    Feb 5, 2020
    Posts:
    17
    I accept and agree with your rant. It's a completely ridiculous oversight for a company of this size.

    Why are the JDK / NDK / SDK fields still fake placeholders s.t. when you uncheck them they are using a different version entirely or no version at all? That's been true for the past decade.
     
    ashishsfb and weto4ka like this.
  24. weto4ka

    weto4ka

    Joined:
    Feb 8, 2019
    Posts:
    48
    I'm curious why these difficulties persist. I believe we have been experiencing challenges with "path" since 2021 or 2020, and they are still present in 2024. Are you planning to fix it?

    We switched between several Unity versions throughout the years, and the most foolish and "hard to debug" issues were usually connected to spaces or naming conventions. You frequently do not assume spaces in paths (and the majority of difficulties when everything should function but does not are caused by a space that Unity does not accept).

    The same is true for the latest Addressable version. It worked fine on the previous two versions. What about the new one? It does not work because it does not properly encode names, thus do not transform spaces to the correct character for URL, and if there is a space in the path for addressables (as was the case in previous versions), your addressables will not download. And it's quite basic.

    I'm truly wondering. Do you consider fixing this?
     
    meemapps likes this.
  25. AndersLindaas

    AndersLindaas

    Joined:
    Nov 12, 2021
    Posts:
    4
    We are also struggling with this. We cannot upgrade to 2022.2+ because of this which is super annoying. We are building in Azure which makes it more difficult to quick fix or trick it to work like suggested here.
     
  26. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    The bug is in Android SDK tools, which is not maintained by Unity. HUB directly gets it from Google servers when installing Unity.

    That's why there's no easy fix here, we also cannot update Android SDK tools in Unity 2021, since that caries a risk of introducing new issues in Unity 2021.

    The easiest way is to simply install to path without whitespaces or apply fix manually like described above.
     
  27. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
  28. Doctor-Chicken

    Doctor-Chicken

    Joined:
    Mar 11, 2024
    Posts:
    4
    I hate to ask, But I was wondering how I can find and delete the "Editor\data\PlaybackEngines\AndroidPlayer\SDK\cmdline-tools"
    as I am very new to unity and have know idea what this is even referring to
     
    meemapps likes this.
  29. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    It's referring to your Unity installation folder.
     
  30. Doctor-Chicken

    Doctor-Chicken

    Joined:
    Mar 11, 2024
    Posts:
    4
    Thanks, I got it working
     
    Tomas1856 likes this.
  31. ArnavSB

    ArnavSB

    Joined:
    Apr 18, 2024
    Posts:
    1
    I have Unity 2023.2.17f1 ,But I have the same error of "Failed to update Android SDK package list. See the Console for details."
    Instead of a version number the Unity editor needed a folder named 'latest' . I added folder named latest and moved the bin folder to it.
    Did i do anything wrong?

    PATH = /usr/bin:/bin:/usr/sbin:/sbin LaunchInstanceID = 2256DDED-BDF0-4607-9C11-DA18DDA77349 SSH_AUTH_SOCK = /private/tmp/com.apple.launchd.1lF5GvOqLI/Listeners HEAP_CLIENT_TOKEN_STAGING = 3786794399 AMPLITUDE_TOKEN_REDBUCKET_PROD = QqyoFpcWPi7V17p80_46CF6-sNGRGbHo AMPLITUDE_TOKEN_YELLOWBUCKET_PROD = Ph-837Q6GNodAkyc2MRkxVPUcjlIET4d HOME = /Users/swarajyaitindia TMPDIR = /var/folders/7v/cs7qwd6144x60pz74cmhq8vh0000gn/T/ ORIGINAL_XDG_CURRENT_DESKTOP = undefined AMPLITUDE_TOKEN_GREENBUCKET_DEV = 84H2gMm_FJzhr3mBaX1lM1JVukmCM7d9 AMPLITUDE_TOKEN_YELLOWBUCKET_DEV = wKi8foVigDditGFvmZewRFWsEbX9Y0YO SHELL = /bin/bash AMPLITUDE_API_KEY_REDBUCKET_PROD = ca12bb461ea96f9bdf5df4ded7d52994 AMPLITUDE_DEPLOYMENT_KEY_RED_BUCKET_PROD = client-zH8Y7OK1i331EKuG77C6UxN8ygcM6LzS COMMAND_MODE = unix2003 AMPLITUDE_API_KEY_REDBUCKET_DEV = 46b8b46515e7632fc42a504b72e05fd0 stderr[ Error: Could not find or load main class com.android.sdklib.tool.sdkmanager.SdkManagerCli Caused by: java.lang.ClassNotFoundException: com.android.sdklib.tool.sdkmanager.SdkManagerCli ] stdout[ ] exit code: 1 UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.AndroidSDKTools.RunAndroidSdkTool (System.String toolName, System.String arguments, System.Boolean updateCommand, System.String errorMsg, System.String toolsDir, System.String[] warningsToIgnore) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.AndroidSDKTools.ListComponentsVersions () (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.SDKManager.UpdatePackagesList () (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.SDKManager.HighestVersionInstalled (UnityEditor.Android.SDKManager+Component tool) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKToolsDetector.GetVersion () (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector.Detect (System.Version minVersion, UnityEditor.Android.PostProcessor.ProgressHandler onProgress) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.EnsureSDKComponentVersion (System.Version minVersion, UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector detector) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <3e55896f454e47f7a06bcf976af266e4>:0) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&) (at /Users/bokken/build/output/unity/unity/Modules/IMGUI/GUIUtility.cs:219)
     
  32. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    142
    using unity 2022.3.25 I STILL have this problem FFS
     
  33. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    142
    DOESNT WORK
     
  34. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,921
    Please post Editor.log
     
  35. YousafGrewal

    YousafGrewal

    Joined:
    Jul 5, 2018
    Posts:
    30
    Why unity soo buggy we try to latest firebase sdk or Admob then unity start problems
     
    Tomas1856 likes this.
  36. omermursel441

    omermursel441

    Joined:
    Saturday
    Posts:
    1
    Unity is really problematic. I don't think the Unity team tested Unity once.
     
  37. rizqiaditya531

    rizqiaditya531

    Joined:
    Dec 21, 2020
    Posts:
    4
    thank you, this really helps me
     
  38. shirsenduadak

    shirsenduadak

    Joined:
    Feb 20, 2023
    Posts:
    1
    I'm getting the same error message while trying to get a build.

    Unity Version: 2022.3.26f1
    OS: macOS Sonoma 14.2.1

    Log:
    Code (csharp):
    1.  
    2. CommandInvokationFailure: Failed to update Android SDK package list.
    3. /Volumes/Data/Shirsendu Data/UnityInstalls/2022.3.26f1/PlaybackEngines/AndroidPlayer/SDK/cmdline-tools/6.0/bin/sdkmanager --list
    4. Environment Variables:
    5. AMPLITUDE_API_KEY_REDBUCKET_DEV = 46b8b46515e7632fc42a504b72e05fd0
    6. DEBUG_ENV_VAR = UnityHub
    7. XPC_FLAGS = 0x0
    8. __CFBundleIdentifier = com.unity3d.unityhub
    9. AMPLITUDE_API_KEY_GREENBUCKET_DEV = 3ded2a762163603391a425f688f990c8
    10. AMPLITUDE_TOKEN_REDBUCKET_DEV = U4PSN7S7PuYVRODivvdcFwbu8R6IHGqa
    11. HOME = /Users/shirsendu.adak
    12. AMPLITUDE_API_KEY_GREENBUCKET_PROD = c86fea37a9e1d3f0878b96e15b111c7c
    13. JAVA_TOOL_OPTIONS = -Dfile.encoding=UTF-8
    14. SENTRY_ACCESS_TOKEN = 3df78d9e53f8456aa90fbae044ce1a6261421ab1d0014674bc2e933477289017
    15. JAVA_HOME = /Volumes/Data/Shirsendu Data/UnityInstalls/2022.3.26f1/PlaybackEngines/AndroidPlayer/OpenJDK
    16. AMPLITUDE_DEPLOYMENT_KEY_RED_BUCKET_DEV = client-wbjHYrmeSR87GmWOE7LDpf7sUySOIKHm
    17. AMPLITUDE_TOKEN_GREENBUCKET_PROD = ZpUcbAdZXJYzNSoHsAWtL_s_JppwWid9
    18. AMPLITUDE_API_KEY = 28f3cae0b33b8b3702120c9ed1a935aa
    19. XPC_SERVICE_NAME = application.com.unity3d.unityhub.24399603.24399609
    20. AMPLITUDE_API_KEY_STAGING = 83ee04fccc67e4fcc7dd527c4c6f1e21
    21. WOOTRIC_CLIENT_TOKEN = NPS-aa8be4c3
    22. USER = shirsendu.adak
    23. MallocNanoZone = 0
    24. LOGNAME = shirsendu.adak
    25. __CF_USER_TEXT_ENCODING = 0x1F6:0:2
    26. AMPLITUDE_API_KEY_YELLOWBUCKET_DEV = 48835b4d1f5e342aefe5f016324d296a
    27. PATH = /usr/bin:/bin:/usr/sbin:/sbin
    28. SSH_AUTH_SOCK = /private/tmp/com.apple.launchd.QKV2nFNTXM/Listeners
    29. AMPLITUDE_API_KEY_YELLOWBUCKET_PROD = e03a9bbe92dc38a88cdb068d24c65b46
    30. AMPLITUDE_TOKEN_REDBUCKET_PROD = jTIgKs5KTZOjiqEEVdZFbgo_VRhABduL
    31. AMPLITUDE_TOKEN_YELLOWBUCKET_PROD = UYDQtPOw83dIfVy3SrW5oMyo7ru4PRkV
    32. COMMAND_MODE = unix2003
    33. TMPDIR = /var/folders/z0/72zd8h491j7b777p7fvc67j40000gp/T/
    34. AMPLITUDE_TOKEN_GREENBUCKET_DEV = 84H2gMm_FJzhr3mBaX1lM1JVukmCM7d9
    35. AMPLITUDE_TOKEN_YELLOWBUCKET_DEV = wKi8foVigDditGFvmZewRFWsEbX9Y0YO
    36. SHELL = /bin/zsh
    37. AMPLITUDE_API_KEY_REDBUCKET_PROD = ca12bb461ea96f9bdf5df4ded7d52994
    38. AMPLITUDE_DEPLOYMENT_KEY_RED_BUCKET_PROD = client-zH8Y7OK1i331EKuG77C6UxN8ygcM6LzS
    39. ORIGINAL_XDG_CURRENT_DESKTOP = undefined
    40. stderr[
    41. Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
    42. Error: Could not find or load main class Data.UnityInstalls.2022.3.26f1.PlaybackEngines.AndroidPlayer.SDK.cmdline-tools.6.0
    43. Caused by: java.lang.ClassNotFoundException: Data.UnityInstalls.2022.3.26f1.PlaybackEngines.AndroidPlayer.SDK.cmdline-tools.6.0
    44. ]
    45. stdout[
    46. ]
    47. exit code: 1
    48. UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    49. UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    50. UnityEditor.Android.AndroidSDKTools.RunAndroidSdkTool (System.String toolName, System.String arguments, System.Boolean updateCommand, System.String errorMsg, System.String toolsDir, System.String[] warningsToIgnore) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    51. UnityEditor.Android.AndroidSDKTools.ListComponentsVersions () (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    52. UnityEditor.Android.SDKManager.UpdatePackagesList () (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    53. UnityEditor.Android.SDKManager.HighestVersionInstalled (UnityEditor.Android.SDKManager+Component tool) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    54. UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKToolsDetector.GetVersion () (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    55. UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector.Detect (System.Version minVersion, UnityEditor.Android.PostProcessor.ProgressHandler onProgress) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    56. UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.EnsureSDKComponentVersion (System.Version minVersion, UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector detector) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    57. UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    58. UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <a799942dddd64d7ab0ff69991e14bcf8>:0)
    59. UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&) (at /Users/bokken/build/output/unity/unity/Modules/IMGUI/GUIUtility.cs:203)