-
Notifications
You must be signed in to change notification settings - Fork 251
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
amplify_auth_cognito:compileDebugJavaWithJavac #4946
Comments
Hello @FabryPostRock - I am sorry to hear you are facing this issue. This is not an error that I have see before. I have a few questions:
|
First of all thank you @Jordan-Nelson for the quick answer. It never worked for me changing to jdk 19 - 21 but i ll try in a few minutes your suggested solution with jdk 17. If I remove all the amplify dependencies it still doesn't build successfully. This is almost new because I remember that removing amplify_auth_cognito it was working. I'll try removing other dependencies step by step. Looking at Gradle Compatibility Matrix it s not necessary to use different Gradle /AGP / Kotlin versions. I think I'll try with Gradle 7.6 , AGP 7.4 , and Kotlin 1.7.10. |
@FabryPostRock Thanks for the info. Let us know if you have any luck with jdk 17 or if you are able to get the project to build without amplify dependencies. |
I have created a new default Flutter project and tried to build it first with jdk 11 without amplify packages and it worked. Then I added all amplify packages and it didn't work. Then i commented the I have also tried jdk 17 with all amplify packages and without |
If this is a new project I would recommend using the latest version of Amplify Flutter (2.0) and to follow the platform setup guide for Android here: https://docs.amplify.aws/gen1/flutter/start/getting-started/setup/ |
I have created a new project with the libraries of my real current project to mess up without problems. Any suggestion about the issue? |
@FabryPostRock - Maybe I misunderstood. Did you have a Flutter application with Amplify Flutter dependencies installed that was previously able to build? |
With amplify dependencies I was never able to build successfully. I just started a default project just to work with libraries and anything else. Do you have any suggested sdk ,gradle , AGP , kotlin configuration for version 1.7.0? I have tried to build with Amplify package 2.0.0 and gradle 8.4 , AGP 7.4.2 , Kotlin 1.9.10 and jdk 17 but without
one thing that bothers me is if i need to update this build.gradle section:
|
Oh my god I finally made it work. Here is my configuration:
pubspec.yaml:
The trick was to configure |
@FabryPostRock I am glad to hear you were able to get this to work. We do list the kotlin, gradle, and AGP versions to use here. These are for the latest version of Amplify Flutter though. If you have any issues using the setup linked above with the latest version of Amplify Flutter, please let us know. I will close this out since it sounds like you have resolved this. |
Hi,
Here are the versions I’m using: Java: 17 Any solution? Thanks, |
Description
Hi everyone!
I m having big trouble in building an app with amplify libraries especially with
amplify_auth_cognito
. It's been days with 0 lines of code!As last chance I tried to build a default flutter project but still I was not able to build with the following error:
Could not resolve all files for configuration ':amplify_auth_cognito:androidJdkImage'. Failed to transform core-for-system-modules.jar to match attributes {artifactType=_internal_android_jdk_image, org.gradle.libraryelements=jar, org.gradle.usage=java-runtime}. Execution failed for JdkImageTransform: C:\Users\xxxx\AppData\Local\Android\sdk\platforms\android-33\core-for-system-modules.jar. C:\Users\xxxx\.gradle\caches\transforms-3\88b68384482bcb9fc6a5fd8fded5da0b\transformed\output\temp\jmod\java.base.jmod
Below here I ll put all my sdk,jdk,pubspec,kotlin configurations:
File->Project Structure->Platform Settings ->SDKs
JDK 11 is set. InFile->Project Structure->Project Settings->Project
no SDK is setLaslty here is my pubspec.yaml:
can you please help me find a solution?
Thank you in advance
Categories
Steps to Reproduce
Screenshots
No response
Platforms
Flutter Version
3.16, 3.22
Amplify Flutter Version
1.7.0
Deployment Method
Amplify CLI
Schema
No response
The text was updated successfully, but these errors were encountered: