I tried to set manually JAVA_HOME and PATH to ‘C:/dev/Unity/Installations/2019.2.2f1/Editor/Data/PlaybackEngines/AndroidPlayer/Tools\OpenJDK\Windows’ and ‘C:/dev/Unity/Installations/2019.2.2f1/Editor/Data/PlaybackEngines/AndroidPlayer/Tools\OpenJDK\Windows\bin’ in my computer’s environment settings, but I’m still getting the same error.
I tried running C:/dev/Unity/Installations/2019.2.2f1/Editor/Data/PlaybackEngines/AndroidPlayer/SDK\tools\bin\sdkmanager.bat --list from cmd and it ran without problems.
Thank you for your reply.
I tried that. I also tried to manually point to the JDK path C:/dev/Unity/Installations/2019.2.2f1/Editor/Data/PlaybackEngines/AndroidPlayer/Tools\OpenJDK\Windows in the preferences, but I got the same weird error.
Upgrading to 2019.2.3f1 fixed the problem however.
Oh my god… It was just as simple as that… I spent lot of time trying to figure out what was wrong…
Had this issue suddenly on unity 2019.3.13f1 (it was working and the day after it wasn’t).
Hi everyone, I have unchecked the box, closed preferences window then opened it again and checked the box. In that way it worked for me
However it’s strange to have such an unsual solution I think it’s that restarting thing with computers
Once again hi everyone, strangely today I had the same issue again. Although the automatically set path is correct, I did as playpes16 said and this time it worked. The path I pasted was the same as the automatically set one but this time Unity wanted in that way I guess
Hi All,
Had the exact same problem, working one day failed the next. This happened after a windows update, which I suspect may have caused the issue. Anyway, my fix was to select browse on JDK & SDK and select the same folders that they are supposedly addressing. Checking and unchecking did not work for me – guess it’s just buggy…
I can also verify the solution, although it is important that when unchecking, you have to close the preference window and then open it again and tick the checkbox again - then it will work.
Checking-unchecking / defining JAVA_HOME manually in the environment variables and other “mumbo-jumbo”-like solutions from the unity team don’t work for me.