skip to Main Content

After downgrading from Gradle 6.1.1 to 7.2 and Android Gradle Build tools 7.1.0 to 4.0.1 (by switching branches in Git) I got the following exception in the Run console (tool window) of Android Studio Bumblebee 2021.1.1 (when trying to run the app on a device):

Unable to determine application id: com.android.tools.idea.run.ApkProvisionException: Couldn't get post build model. Module: My_App.app Variant: debug

The Grade build runs successfully but the app won’t be installed in the device.

2

Answers


  1. Chosen as BEST ANSWER

    In Android Studio run File > Invalidate Caches ... and restart (you don't need to select the optional "Clear file system cache and Local History"). Just to be sure, also run Build > Clean Project.


  2. I have faced this issue when i upgrade to android studio Dolphin. So for me this workaround was to delete the existing app configuration from Run/Debug Configurations.
    enter image description here

    After that add new configuration by clicking the left top + icon and then add Android App.

    enter image description here

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search