Android Studio - Gradle sync failed: Already disposed

As it turned out, the problem was that I was trying to open a project directory that was a symlink to the actual location (on the same partition). Gradle (on command line) had no issues building the project from the symlinked location, however, opening it in Android Studio resulted in the obscure and non helpful error described above.


Simple solution

    1.Delete module folder and modules.xml file under .idea folder. 
    2.Close Android Studio
    3.Reopen and sync

Possible duplicate problem:
Android Studio 3.0 - Unable to save settings: Failed to save settings. Please restart Android Studio Android Studio 3.0 - Unable to save settings: Failed to save settings. Please restart Android Studio

This worked for me: Delete the .idea folder.

1) Go to File--> Settings -->Plugins Disable any plugins not loaded (i.e. red in color) @friederbluemle This may not apply to you.

2) Enable the one plugin, Android Support

3) Right-click on your 'app' directory (contains your module gradle.build file) in Android Studio and select 'Show in Explorer' --- this opens that directory.

4) Quit Android Studio. Get out of any and all instances of Android Studio to allow you to then delete the fold, .idea, in that directory.

5) Restart AS, you'll notice the project will not come up -- you'll have to pick in the dialog window that appears. That's ok. Pick it, and it will 'rebuild' the folder, .idea.

6) Go to File--> Settings -->Plugins Enable any and all plugins if any.