Please update the Mobile Apps How To Doc regarding Capacitor, Android Apps, Android Studio, and running Wappler apps in the Android Emulator. The process detailed in the current how to doc no longer works. Multiple other people in the community are experiencing the same problem. Many different fixes and work arounds have been attempted to no avail.
I am now imploring Wappler to please show us how it is done as of June 2023.
I found a solution and wanted to share. I spent weeks ripping my hair out over this and am stoked to have finally figured it out.
Upgrade to AS Flamingo (I know, many of us thought this was the problem, but stick with me here)
Install SDK 33 (not 31 like Wappler docs say, and not 34 which is the default). Also make sure you have command line tools installed and your desired emulators set up. Also make sure you have downloaded the disk images from the SDK package.
Open the Android folder from your Wappler project in Android Studio (if you haven’t added it from Wappler yet, do so now. Or if you already have, delete it and re-add it to your Wappler project so you can start fresh.
Under project structure set Android Gradle Plugin Version to 7.4.2
Then set Gradle version to 7.5 (this will get you past the namespace error)
Now at this point to project will build but will not run. When you try to run you will likely get the duplicate classes error. This is something dumb in Kotlin. but I have a hacky fix here:
Open your build.gradle (Module :app) file (NOT build.gradle (Project :android)…important distinction)
Paste the following code at the very bottom of that file