Android AS Run main Method Error [How to Solve]

Environment: Android Studio4.2.2

Modify the gradle.xml file under project .idea to add

<option name="delegatedBuild" value="false" />

Screenshot:


Rebuild will be OK!

Read More: