skip to Main Content

so i just updated my windows from 10 to 11 and also android studio to new 2021bumblbee

now I am facing errors in every project
I tried reinstalling android studio ,java and windows 11
invalidating catch, recreating new projects, updating all plugins
,re-downloading dependencies but still the same error

currently, i am using Android Gradle plugin version 7.0.4 and Gradle version 7.0.2

class org.codehaus.groovy.ast.expr.TupleExpression cannot be cast to class org.codehaus.groovy.ast.expr.ArgumentListExpression (org.codehaus.groovy.ast.expr.TupleExpression and org.codehaus.groovy.ast.expr.ArgumentListExpression are in unnamed module of loader org.gradle.internal.classloader.VisitableURLClassLoader @42d80b78)
class org.codehaus.groovy.ast.expr.TupleExpression cannot be cast to class org.codehaus.groovy.ast.expr.ArgumentListExpression (org.codehaus.groovy.ast.expr.TupleExpression and org.codehaus.groovy.ast.expr.ArgumentListExpression are in unnamed module of loader org.gradle.internal.classloader.VisitableURLClassLoader @42d80b78)

Gradle's dependency cache may be corrupt (this sometimes occurs after a network connection timeout.)

Re-download dependencies and sync project (requires network)
The state of a Gradle build process (daemon) may be corrupt. Stopping all Gradle daemons may solve this problem.

Stop Gradle build processes (requires restart)
Your project may be using a third-party plugin which is not compatible with the other plugins in the project or the version of Gradle requested by the project.

In the case of corrupt Gradle processes, you can also try closing the IDE and then killing all Java processes.


2

Answers


  1. Chosen as BEST ANSWER

    I didn't get what was causing the problem but after reinstalling windows 11 and android studio again it works now


  2. Try this solution :
    Go for Settings then ->Use embedded jdk
    enter image description here

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