- Edited
flutter yazılımına daha yeni başladım. fluttergithub adersinden örnek bir kod aldım ve bu hatayı alıyorum herhangi bir yeni proje oluşturduğumda ise aynı hatayı almaktayım nasıl çözebilirim. yardımcı olurmusunuz?
flutter yazılımına daha yeni başladım. fluttergithub adersinden örnek bir kod aldım ve bu hatayı alıyorum herhangi bir yeni proje oluşturduğumda ise aynı hatayı almaktayım nasıl çözebilirim. yardımcı olurmusunuz?
emin_darkk jdk kurulu değil gibi görünüyor.
komut satırına flutter doctor yazıp çıktıyı atar mısınız
Aynı hatayı alıyorum, aşağıdaki komut satırındaki çıktı;
Launching lib/main.dart on Android SDK built for arm64 in debug mode…
Running Gradle task ‘assembleDebug’…
FAILURE: Build failed with an exception.
Failed to query the value of task ‘:app:compileDebugKotlin’ property ‘compilerRunner$kotlin_gradle_plugin’.
Kotlin could not find the required JDK tools in the Java installation. Make sure Kotlin compilation is running on a JDK, not JRE.
Try:
Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output. Run with –scan to get full insights.
Get more help at https://help.gradle.org
BUİLD FAILED in 14s
Exception: Gradle task assembleDebug failed with exit code 1
Bu da “flutter doctor” komutunun çıktısı (Mac kullanıyorum)
Last login: Sat Mar 5 17:13:52 on ttys000
dimitar@dimitar-air ~ % flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.10.3, on macOS 12.1 21C52 darwin-arm, locale
tr-TR)
[!] Android toolchain - develop for Android devices (Android SDK version
32.1.0-rc1)
✗ cmdline-tools component is missing
Run path/to/sdkmanager --install "cmdline-tools;latest"
See https://developer.android.com/studio/command-line for more details.
✗ Android license status unknown.
Run flutter doctor --android-licenses
to accept the SDK licenses.
See https://flutter.dev/docs/get-started/install/macos#android-setup for
more details.
[!] Xcode - develop for iOS and macOS (Xcode 13.2.1)
✗ CocoaPods not installed.
CocoaPods is used to retrieve the iOS and macOS platform side’s plugin
code that responds to your plugin usage on the Dart side.
Without CocoaPods, plugins will not work on iOS or macOS.
For more info, see https://flutter.dev/platform-plugins
To install see
https://guides.cocoapods.org/using/getting-started.html#installation for
instructions.
[✓] Chrome - develop for the web
[!] Android Studio (not installed)
[✓] Connected device (2 available)
[✓] HTTP Host Availability
! Doctor found issues in 3 categories.
dimitar@dimitar-air ~ %
flutter doctor --android-licenses
yazın emülatöre öncelikle. Ardından
path/to/sdkmanager --install "cmdline-tools;latest"
Selamlar tekrar, bir arkadaşla kurcalayıp aynı projeyi aynı değerlerle tekrar başlattıktan sonra (BTK akademiden izliyorum dersleri) aldığım hata değişti. Aşağıya yeni hata kodunu paylaşıyorum.
Launching lib/main.dart on Android SDK built for arm64 in debug mode…
Running Gradle task ‘assembleDebug’…
FAILURE: Build failed with an exception.
java.lang.IllegalAccessError: class org.gradle.internal.compiler.java.ClassNameCollector (in unnamed module @0×645f1697) cannot access class com.sun.tools.javac.code.Symbol$TypeSymbol (in module jdk.compiler) because module jdk.compiler does not export com.sun.tools.javac.code to unnamed module @0×645f1697
Try:
Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output. Run with –scan to get full insights.
Get more help at https://help.gradle.org
BUİLD FAILED in 47s
Exception: Gradle task assembleDebug failed with exit code 1
Last login: Mon Mar 7 21:28:17 on ttys001
dimitar@dimitar-air ~ % flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.10.3, on macOS 12.1 21C52 darwin-arm, locale
tr-TR)
[!] Android toolchain - develop for Android devices (Android SDK version
32.1.0-rc1)
✗ cmdline-tools component is missing
Run path/to/sdkmanager --install "cmdline-tools;latest"
See https://developer.android.com/studio/command-line for more details.
✗ Android license status unknown.
Run flutter doctor --android-licenses
to accept the SDK licenses.
See https://flutter.dev/docs/get-started/install/macos#android-setup for
more details.
[!] Xcode - develop for iOS and macOS (Xcode 13.2.1)
✗ CocoaPods not installed.
CocoaPods is used to retrieve the iOS and macOS platform side’s plugin
code that responds to your plugin usage on the Dart side.
Without CocoaPods, plugins will not work on iOS or macOS.
For more info, see https://flutter.dev/platform-plugins
To install see
https://guides.cocoapods.org/using/getting-started.html#installation for
instructions.
[✓] Chrome - develop for the web
[!] Android Studio (not installed)
[✓] Connected device (2 available)
[✓] HTTP Host Availability
! Doctor found issues in 3 categories.
dimitar@dimitar-air ~ %
Biraz araştırdıktan sonra lisans sorununu çözdüm son durum;
Launching lib/main.dart on Android SDK built for arm64 in debug mode…
Running Gradle task ‘assembleDebug’…
FAILURE: Build failed with an exception.
java.lang.IllegalAccessError: class org.gradle.internal.compiler.java.ClassNameCollector (in unnamed module @0×645f1697) cannot access class com.sun.tools.javac.code.Symbol$TypeSymbol (in module jdk.compiler) because module jdk.compiler does not export com.sun.tools.javac.code to unnamed module @0×645f1697
Try:
Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output. Run with –scan to get full insights.
Get more help at https://help.gradle.org
BUİLD FAILED in 4s
Exception: Gradle task assembleDebug failed with exit code 1
Ve “flutter doctor” son durumu;
Last login: Tue Mar 8 19:33:43 on ttys001
dimitar@dimitar-air ~ % flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.10.3, on macOS 12.1 21C52 darwin-arm, locale
tr-TR)
[✓] Android toolchain - develop for Android devices (Android SDK version
32.1.0-rc1)
[!] Xcode - develop for iOS and macOS (Xcode 13.2.1)
✗ CocoaPods not installed.
CocoaPods is used to retrieve the iOS and macOS platform side’s plugin
code that responds to your plugin usage on the Dart side.
Without CocoaPods, plugins will not work on iOS or macOS.
For more info, see https://flutter.dev/platform-plugins
To install see
https://guides.cocoapods.org/using/getting-started.html#installation for
instructions.
[✓] Chrome - develop for the web
[!] Android Studio (not installed)
[✓] Connected device (2 available)
[✓] HTTP Host Availability
! Doctor found issues in 2 categories.
dimitar@dimitar-air ~ %
java sürümlerini sil sonrada şunu izle üstat yapmadıklarını yap. gerekli java ismi geçiyor onuda indirip kurarsın lisanslamayıda yine videoda paylaşmış. flutter doctor -lisasnces gibi bişeydi sanırım
Maalesef işe yaramadı, jdk ekledim ancak aşağıdaki hatayı vermeye devam ediyor;
Launching lib/main.dart on Android SDK built for arm64 in debug mode…
Running Gradle task ‘assembleDebug’…
FAILURE: Build failed with an exception.
java.lang.IllegalAccessError: class org.gradle.internal.compiler.java.ClassNameCollector (in unnamed module @0×34673f54) cannot access class com.sun.tools.javac.code.Symbol$TypeSymbol (in module jdk.compiler) because module jdk.compiler does not export com.sun.tools.javac.code to unnamed module @0×34673f54
Try:
Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output. Run with –scan to get full insights.
Get more help at https://help.gradle.org
BUİLD FAILED in 3s
Exception: Gradle task assembleDebug failed with exit code 1
dimitar Bu sorunu çözebildiniz mi, ben android studio güncellemesi yaptım ve hala bu sorunu alıyorum. Hiçbir uygulamam da androidde çalışmıyor
NurhayatYurtaslan
https://www.oracle.com/java/technologies/downloads/#jre8-windows
buradan jre ve jdk kurulumu yapın. JRE kurduğunuz dizini Ortam Değişkenlerine JAVA_HOME ismiyle ekleyin. Studio’yu kapatıp yeniden başlatın ve tekrar deneyin.
HseyinAkkaya şu an peki son güncelleme ile de mi java 8 kullanıyorsunuz. Ben daha güncelleme yeni yaptim son sürümune ve bu hata ile karşılaştım