Closed JuYiYang closed 2 weeks ago
Hi @JuYiYang, you are using an older version of flutter. Kindly upgrade to the latest version of flutter stable (3.19.5) to see if you still experience this issue. You might need to modify your build.gradle file. See https://docs.flutter.dev/release/breaking-changes/flutter-gradle-plugin-apply
If you still experience this issue after the upgrade, kindly provide the full crash log in a .log or .txt file along with your android/build.gradle
, android/app/build.gradle
& settings.gradle
files.
Thank you
Is there a way to not upgrade the SDK? Since I am maintaining this project, I am not sure what will cause the upgrade, as it is normal for the project to be packaged under another employee's computer (macbook).
We will need the full out of flutter build apk -v
to determine where the issue is coming from, maybe then we could offer a solution.
Please provide the full output of flutter build apk -v
in a .txt or .log file and not only the error, it is likely something is going wrong before the error you posted above.
I replaced a computer to re-package the project, and found that it could be normally packaged, but it would report some kotlin errors
The kotlin warnings are largely harmless, you can see how to fix similar issues by following https://stackoverflow.com/questions/67448034/module-was-compiled-with-an-incompatible-version-of-kotlin-the-binary-version.
If you are able to build the apk successfully on a different issue, that suggests that there might be something wrong with the gradle cache on the laptop you were using initially, without further logs, we can't do much to assist.
Now I can't find any complete log, I suspect it is the problem of flutte downgrade version, I downgraded from 3.19.3 to 3.13.9 on the original computer, may be cached after the downgrade?
You can always get the logs by running the flutter build apk -v
command. You can also try clearing your .pub-cache and your .gradle caches to see if it helps
emm,How do I know which version of kotlin my project needs when my console keeps reporting kotlin errors
You can always get the logs by running the
flutter build apk -v
command. You can also try clearing your .pub-cache and your .gradle caches to see if it helps
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v
and a minimal reproduction of the issue.
flutter --version
flutter doctor -v
flutter build apk --release (Error section)