Search Unity

Unity 2018.4.18f1 randomly removes Android Platform

Discussion in 'Android' started by Lord_Eniac, Jul 12, 2020.

  1. Lord_Eniac

    Lord_Eniac

    Joined:
    Jan 28, 2020
    Posts:
    50
    About once a month, Unity decides that I really don't want the Android platform installed anymore. I start up Unity, and I get a message stating that the Android platform is not a valid platform. I have to switch to PC or quit. I switch to PC, exit, re-install the Android platform (I've gotten pretty good at this since it started happening in May),and then restart Unity. Of course, I have to switch platforms back to Android.

    Then rinse and repeat as needed.

    Why is this happening, and is there a fix?
     
  2. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,917
    Unity isn't capable of removing Android support manually, Android support is present in <UnityInstallation>\Editor\Data\PlaybackEngines\AndroidPlayer, check if that folder exists.

    If that folder exists, and Unity shows that Android support is not present, please attach Editor.log, maybe it will contain useful information.

    Also, do you have antivirus installed, wondering if antivirus is not putting some file to vault, causing Unity to mistakenly say Android is not installed.
     
  3. Lord_Eniac

    Lord_Eniac

    Joined:
    Jan 28, 2020
    Posts:
    50
    I agree 100%. Unity shouldn't be capable of removing the platform arbitrarily. And, yes, the platform folder is still there. It's like all references to it have been hosed. The only viable option (quit is not really an option) is to let Unity convert my project back to the default platform (PC in my case). Then I shut Unity down, "re-install" what supposedly is already there, and things are back to normal for a few weeks. Then the same thing happens again... What prompted this question was that I quit Unity, remembered that I had to do something, started Unity back again and immediately got the error.

    As for the editor log, I'm looking for it. Any pointers on where it might be (project folder, ProgramData, Roaming folder, etc.)?
     
  4. Lord_Eniac

    Lord_Eniac

    Joined:
    Jan 28, 2020
    Posts:
    50
    Ok, found the folder with the editor logs. However, it looks like Unity only just keeps the current and previous editor logs, so that's unfortunately not going to help right now. I'll have to wait for this to happen again, and given that it's happened three times now, a fourth is certain to occur sometime in the near future.
     
    Tomas1856 likes this.
  5. Lord_Eniac

    Lord_Eniac

    Joined:
    Jan 28, 2020
    Posts:
    50
    And it happened again..., but I have captured the logs this time. One new symptom to add to the mix is that this time prior to shutting Unity down, I tried to run my app, but the editor was reporting that there were two compiler errors that needed to be fixed. I had just built an Android build (successfully, I'll add) a few hours before, and not having changed anything prior to running, I looked at the "errors". Both of the errors were in the log, but they were completely blank. No text, nothing. I restarted Unity and was greeted with the error again.

    Is there some place (email preferrably) that I can send the log information?
     

    Attached Files: