Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We’re making changes to the Unity Runtime Fee pricing policy that we announced on September 12th. Access our latest thread for more information!
    Dismiss Notice
  3. Dismiss Notice

Bug Unity HUB cannot download Android SDK/NDK in any Unity 2022 version

Discussion in 'Unity Hub' started by jeremyfryc, Feb 23, 2023.

  1. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    I believe this problem has been discussed before, but never truly resolved. I'm using Unity Hub (3.4.1) on my iMac (Ventura 13.1), and I'm trying to download a 2022 Unity version with Android SDK, but as the screenshot shows, the download fails (this occurs with every Unity 2022 version):

    Screenshot 2023-02-22 at 7.03.08 PM.png

    The reason I specifically want to update to a Unity 2022 version is because of the end of this thread:

    https://forum.unity.com/threads/upload-app-larger-than-150mb.1334297/#post-8770315
    (quick summary: despite asset bundling everything in my project, I couldn't get the base-master.apk under 150MB, I could only get it to 178MB. Word on the street is that this was actually an Unity issue. So, I'm upgrading to a 2022 version to try my luck).

    I have tried just opening my project in a Unity 2022 version, and then copying the Android Studio file path to the Android SDK in the "External Tools" menu in Unity's preferences... but that doesn't work. Can't create a build because "Android SDK is not found or is invalid".

    So, does anybody know how to fix this? Thanks!
     
  2. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,630
  3. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Sure thing. I had to redownload Unity 2022.2.7f1, and I received these errors:

    Screenshot 2023-02-23 at 12.35.34 PM.png

    Please find attached the info-log.json file. Let me know what you think. Thanks!
     

    Attached Files:

  4. Gennady

    Gennady

    Unity Technologies

    Joined:
    Mar 30, 2015
    Posts:
    39
    Hi, could you please try to:

    1. Uninstall the Editor
    2. Completely quit the Hub (not just close the window, but quit from the tray menu)
    3. Run the Hub
    4. Install the Editor with modules

    Thank you!
     
  5. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Thanks for the suggestion. Not only did I restart Unity Hub, I restarted my computer as well. The result is the same as the beginning:

    Screenshot 2023-02-23 at 9.18.07 PM.png

    You can find the info-log.json file attached.

    What do you think I can try next? Thank you.
     

    Attached Files:

  6. Gennady

    Gennady

    Unity Technologies

    Joined:
    Mar 30, 2015
    Posts:
    39
    Could you please try to install Editor with no modules and then install modules one-by one?
     
  7. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Thanks for getting back. I did try this -- unfortunately, the result is the same. As you suggested, I first installed Unity 2022.2.7.f1 with no modules. After it installed, I went to "Add Modules" and selected the Android modules.

    The download was "Completed with Errors" at 7 out of 10 steps:

    Screenshot 2023-02-28 at 4.40.08 PM.png

    Interestingly, I then went to check to see if I could add those modules again, and this is what I see:

    Screenshot 2023-02-28 at 4.40.36 PM.png

    So, Unity Hub believes that the modules are indeed installed, but they aren't. Because when I try to create a build, Unity says that there is no Android SDK in the console.

    What do you think is going on here? What does "Download Failed: read ECONNRESET" mean?

    I look forward to hearing back. Thanks!
     
  8. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Hello Gennady. I wanted to get back with you and Unity since I have updated the Unity Hub to the latest version (3.4.2). I thought that maybe this would solve the Android SDK issue, but the issue persists. You can see this in the screenshot below.

    Do you and/or Unity have any more ideas about what can be done to successful install an Android SDK in a Unity 2022 version? Let me know. Thanks.

    Screenshot 2023-04-18 at 5.06.21 PM.png
     
  9. judesidloski

    judesidloski

    Unity Technologies

    Joined:
    May 12, 2022
    Posts:
    3
    Hi Jeremy,

    Have you had a chance to report this through the Hub bug reporter? That is the best action I can recommend since it will get you in touch with a QA who will be able to give you the best guidance on troubleshooting steps, and at the same time it will also start the process of getting a bug in front of the dev team so that this issue can be fixed.

    If this is blocking you then it may be possible to install the android modules without the hub. See https://docs.unity3d.com/Manual/and...r/.-,Customizing dependencies,-You should use

    In terms of understanding the bug this would also be a great step to take because it will help us to understand if this is strictly a hub issue or perhaps an issue with installing the modules in general.

    Thank you for your patience.
     
  10. spacefrog

    spacefrog

    Joined:
    Jun 14, 2009
    Posts:
    728
    This is a blocking issue for CI/CD using gitlab and Unity Docker images
    As posted over here, the Unity docker images rely on the hub to install the correct SDK for android builds, but all the 2022.2 docker images fail to build to android because of this hub issue !
    Its absolutely insane that this issue with the hub is unsolved for so long, while professional studios are blocked from upgrading to the most recent techstream versions and are stuck on 2022.1 versions because of it
     
    soleron likes this.
  11. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    512
    @judesidloski

    Same issue here. Both on latest Production (3.4.2) and Beta releases of the Hub.

    Happens on 2022.2.9+ and 2023.x
    2022.2.8f1 downloads without issues.


    I am not sure what method is used for distribution, but I somehow believe that using torrent would be far less problematic :D

    Update: Installing by clicking on the website [Unity Hub] button works like a charm. Same version by clicking in the hub directly, fails to install.
     
    Last edited: Apr 26, 2023
  12. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Thanks for letting me know that I'm not alone. I do hope this gets resolved!

    Thanks for that. Quick question -- which thing did you click on to get it to install correctly? I clicked on "Unity Hub" next to Unity 2022.2.8, but this did not work (see screenshot):

    Screenshot 2023-05-01 at 3.46.34 PM.png

    When I did that I got the same result, as can be seen in the next screenshot:

    Screenshot 2023-05-01 at 3.48.02 PM.png

    Is there something you did that I'm not doing? Let me know. Thanks!

    Thank you. Apologies for taking so long to respond. Lots of things going on right now. Unfortunately, the documentation seems to be out of date and no longer is helpful. But I will file an official bug report. Thanks.
     
  13. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    512

    I did exactly the same. Click on the "Unity Hub" button and the installation worked fine.

    But I see you have a different error than the one I saw.

    This is the error that I see

    upload_2023-5-4_18-26-56.png
     
    Last edited: May 4, 2023
  14. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Very interesting. I reported the bug to Unity. I'm wondering if this is specific to certain computers. I ended up using my work computer and I was able to download successfully Unity version 2022.2.17f1 with Android modules via Unity Hub.

    So, my work computer is: MacBook Pro 2019, 16GB, 2.6 GHz 6-Core Intel Core i7.

    But this still doesn't work on my personal computer, no matter what I do.

    My personal computer is: iMac 2017, 16GB, 3.4 GHz Quad Core Intel Core i5

    I wonder if there is an issue with certain kinds of computers. What kind of computer do you have? Curious to compare specs.
     
  15. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    512

    ASUS ROG Strix, intel i7 CPU , 32GB RAM, 8GB RTX GPU.
     
  16. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Whelp, that throws that theory out the window. I guess it's still a mystery.
     
  17. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    512

    This has started recently along with other download issues on my computer.

    I think there is some updated 3rd party network/connectivity software component somewhere which affects a certain way of downloading. For some time now I only download big files on my Mobile and then copy them to my PC.

    It does not affect system downloads, i.e. Windows updates, or OneDrive sync, Microsoft Store or Steam and Epic downloads. but it does affect other downloads. i.e. browser downloads and the Unity Hub.

    Also Plastic is having problems uploading from Unity.
    But no issue whatsoever when uploading from the standalone client.


    So, there must be something, somewhere, in common. Probably some 3rd party component commonly used in browsers and also used in the Hub. Just no way for us to figure it out without detailed diagnostics and comparisons of web routing and all in between processes.

    One thing is certain, it is not the OS. Otherwise, all downloads would fail.
     
  18. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Ugh. I think you're right. On the other hand, I heard back directly from Unity about the bug report I filed regarding this issue. Here is what they said:

    Hello! Thank you for reporting this issue, I’ve conversed with one of the developers that replied in the forum thread and they will go ahead and attempt to see what is causing the issue. But for now, you can manually install the module without using the Unity Hub by following these steps:
    1. Go into our download archive [https://unity.com/releases/editor/archive|https://unity.com/releases/editor/archive|smart-link]
    2. Choose the version you wish to install/use
    3. Select the “Downloads(OS)” button drop-down (depending on your OS)
    4. In the drop-down select the “Unity Installer” selection
    5. When installing select only the module you wish to install excluding every other selection
    This workaround in theory should work. If you have any additional questions or require further assistance, please feel free to reach out!

    Regards,
    Gediminas Customer QA Team

    Does that help you think? I haven't tried it yet, since I got it downloaded on another computer (not my main computer).
     
    soleron likes this.
  19. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    512
    Well, that circumvents the Hub and downloads the components directly. Like it used to be in the past.

    So it could be the solution but does not fix the Hub problem. You could try it.

    Also here you can find the Alpha versions https://unity.com/releases/editor/alpha
    And here you can find the Beta if you need it. https://unity.com/releases/editor/beta
     
  20. jeremyfryc

    jeremyfryc

    Joined:
    Mar 11, 2014
    Posts:
    92
    Sounds like a plan. I hope they fix this soon.
     
  21. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    512
    I was able to install the latest 2023.2 alpha. Just not use it through the Hub.
     
  22. magesteve

    magesteve

    Joined:
    Aug 2, 2023
    Posts:
    1
    I am also having this issue with my PC & Mac machine, when installing 2022.3.6f1, with Android support. I see the same messages about validation error as shown by Jeremy. To get around it, I left the install half done, and tried to compile a Quest app. I had to to manually installed the Android ADB, but after that I was able to make a VR Quest project. Later, I went back to my PC, and tried to install 2021.3.29f1 & 2020.3.28f1, and had the same errors.