Giter Club home page Giter Club logo

Comments (17)

chkfung avatar chkfung commented on July 24, 2024 8

JDK need to be at least 11, ref

Java 11 requirement
With AGP 7.0.0-alpha01 we are changing the minimum required Java programming language version to Java 11. We are announcing this early in the Canary schedule and many months ahead of the stable release to allow developers time to get ready.

from android-dev-challenge-compose.

kalpeshp0310 avatar kalpeshp0310 commented on July 24, 2024 4

Using embedded JDK which ships with Android Studio also works.

from android-dev-challenge-compose.

jflavio11 avatar jflavio11 commented on July 24, 2024 3

Changing the project JDK to 11 from File -> Project Structure did the trick! Thanks! 🥳

from android-dev-challenge-compose.

orgmir avatar orgmir commented on July 24, 2024 1

In my case, I updated kotlin version to 1.4.31 and it wasn't working. It has to be 1.4.30 for this to work!

from android-dev-challenge-compose.

issamux avatar issamux commented on July 24, 2024 1

./gradlew build --stacktrace

An exception occurred applying plugin request [id: 'com.android.application']

Failed to apply plugin 'com.android.internal.application'.
Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
You can try some of the following options:
- changing the IDE settings.
- changing the JAVA_HOME environment variable.
- changing org.gradle.java.home in gradle.properties.

Gradle plugin requires Java 11 to run.?!!!

from android-dev-challenge-compose.

GuilhE avatar GuilhE commented on July 24, 2024

Actually I can only make it work with classpath 'com.android.tools.build:gradle:4.1.2' because using alph07 it asks me to upgrade to 08, and then the above error is thrown.

I'm missing something here for sure, 'cause compose is failling to:

Execution failed for task ':app:prepareDebugKotlinCompileTask'.
> Could not resolve all files for configuration ':app:kotlin-extension'.
   > Could not find androidx.compose:compose-compiler:1.0.0-beta01.
     Searched in the following locations:
       - https://dl.google.com/dl/android/maven2/androidx/compose/compose-compiler/1.0.0-beta01/compose-compiler-1.0.0-beta01.pom
       - https://jcenter.bintray.com/androidx/compose/compose-compiler/1.0.0-beta01/compose-compiler-1.0.0-beta01.pom
     Required by:
         project :app

Possible solution:
 - Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html



Execution failed for task ':app:prepareDebugKotlinCompileTask'.
> Could not resolve all files for configuration ':app:kotlin-extension'.
   > Could not find androidx.compose:compose-compiler:1.0.0-alpha12.
     Searched in the following locations:
       - https://dl.google.com/dl/android/maven2/androidx/compose/compose-compiler/1.0.0-alpha12/compose-compiler-1.0.0-alpha12.pom
       - https://jcenter.bintray.com/androidx/compose/compose-compiler/1.0.0-alpha12/compose-compiler-1.0.0-alpha12.pom
     Required by:
         project :app

Possible solution:
 - Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html


from android-dev-challenge-compose.

dekzitfz avatar dekzitfz commented on July 24, 2024

same here, I think the beta version of jetpack compose not yet live on maven? because the latest version listed is 1.3.0-alpha02

from android-dev-challenge-compose.

JolandaVerhoef avatar JolandaVerhoef commented on July 24, 2024

Make sure to download Android Studio Arctic Fox Canary 8. Gradle plugin versions are linked to Android Studio versions, so this should help get that version resolved.

from android-dev-challenge-compose.

shengMR avatar shengMR commented on July 24, 2024

确保下载Android Studio Arctic Fox Canary8。Gradle插件版本已链接到Android Studio版本,因此这应有助于解决该版本。

I also had this problem using Android Studio Arctic Fox Canary 8.

from android-dev-challenge-compose.

GuilhE avatar GuilhE commented on July 24, 2024

Make sure to download Android Studio Arctic Fox Canary 8. Gradle plugin versions are linked to Android Studio versions, so this should help get that version resolved.

Hello @JolandaVerhoef, I'm using that version.

from android-dev-challenge-compose.

JolandaVerhoef avatar JolandaVerhoef commented on July 24, 2024

It seems you might have issues accessing maven.google.com (see android/architecture-components-samples#25). The latest versions are available there. Can you try the work-arounds described in the linked issue?

from android-dev-challenge-compose.

dekzitfz avatar dekzitfz commented on July 24, 2024

Make sure to download Android Studio Arctic Fox Canary 8. Gradle plugin versions are linked to Android Studio versions, so this should help get that version resolved.

do we need to redownload SDK using AS canary? in this case I'm using my existing android SDK and JDK

from android-dev-challenge-compose.

hqrachel avatar hqrachel commented on July 24, 2024

Using Android Studio Arctic Fox Canary 8 works for me.

from android-dev-challenge-compose.

GuilhE avatar GuilhE commented on July 24, 2024

JDK need to be at least 11, ref

Java 11 requirement
With AGP 7.0.0-alpha01 we are changing the minimum required Java programming language version to Java 11. We are announcing this early in the Canary schedule and many months ahead of the stable release to allow developers time to get ready.

Well that was it! I'm using Android Studio 4.1.2 in my production projects so I didn't know with Canary I had to use Java 11.
Thank you so much!

from android-dev-challenge-compose.

zsqw123 avatar zsqw123 commented on July 24, 2024

JDK need to be at least 11, ref

Java 11 requirement
With AGP 7.0.0-alpha01 we are changing the minimum required Java programming language version to Java 11. We are announcing this early in the Canary schedule and many months ahead of the stable release to allow developers time to get ready.

I've been using Java11 and still can't solve the problem :(

from android-dev-challenge-compose.

zsqw123 avatar zsqw123 commented on July 24, 2024

JDK need to be at least 11, ref

Java 11 requirement
With AGP 7.0.0-alpha01 we are changing the minimum required Java programming language version to Java 11. We are announcing this early in the Canary schedule and many months ahead of the stable release to allow developers time to get ready.

I've been using Java11 and still can't solve the problem :(

Ah, this is my fault, even though I have upgraded to Java 11, and the version I executed "java -version" is also 11.0.10, but I still need to configure the location of Java 11 in the Project structure.

from android-dev-challenge-compose.

issamux avatar issamux commented on July 24, 2024

Android Studio Arctic Fox Canary 8

Same problem using Android Studio Arctic Fox Canary 10
`An exception occurred applying plugin request [id: 'com.android.application']

Failed to apply plugin 'com.android.internal.application'.
java.lang.NoSuchMethodException: java.lang.invoke.MethodHandles.privateLookupIn(java.lang.Class, java.lang.invoke.MethodHandles$Lookup)
`

from android-dev-challenge-compose.

Related Issues (8)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.