Skip to content
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

issue occurs while run flutter app #86924

Closed
kavita665 opened this issue Jul 23, 2021 · 9 comments
Closed

issue occurs while run flutter app #86924

kavita665 opened this issue Jul 23, 2021 · 9 comments
Labels
r: timeout Issue is closed due to author not providing the requested details in time

Comments

@kavita665
Copy link

  • What went wrong:
    Could not open settings generic class cache for settings file 'D:\KAVITA\flutter project\firstproject\android\settings.gradle' (C:\Users\Kavita Singh.gradle\caches\6.7\scripts\1fnwrr8g4rohfp291nvlxj5qe).

BUG! exception in phase 'semantic analysis' in source unit 'BuildScript' Unsupported class file major version 60

  • 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

BUILD FAILED in 4s

@kavita665
Copy link
Author

kavita665 commented Jul 23, 2021

Any help or ideas that why this exception occur.

@maheshj01 maheshj01 added the in triage Presently being triaged by the triage team label Jul 23, 2021
@maheshj01
Copy link
Member

Hi, @kavita665 could you please share the output of flutter doctor -v along with the steps to reproduce the issue.

Thank you.

@maheshj01 maheshj01 added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Jul 23, 2021
@kavita665
Copy link
Author

D:\KAVITA\flutter project\firstproject> flutter doctor -v
[√] Flutter (Channel stable, 2.2.3, on Microsoft Windows [Version 10.0.19043.928], locale en-US)
• Flutter version 2.2.3 at D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter
• Framework revision f4abaa0 (3 weeks ago), 2021-07-01 12:46:11 -0700
• Engine revision 241c87ad80
• Dart version 2.13.4

[√] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
• Android SDK at C:\Android\Sdk
• Platform android-31, build-tools 31.0.0
• ANDROID_HOME = C:\Android\Sdk
• Java binary at: C:\Program Files\java\jdk-16.0.2\bin\java.exe
• Java version Java(TM) SE Runtime Environment (build 16.0.2 7-67)
• All Android licenses accepted.

[√] Chrome - develop for the web
• Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[!] Android Studio (not installed)
• Android Studio not found; download from https://developer.android.com/studio/index.html
(or visit https://flutter.dev/docs/get-started/install/windows#android-setup for detailed instructions).

[√] VS Code (version 1.58.2)
• VS Code at C:\Users\Kavita Singh\AppData\Local\Programs\Microsoft VS Code
• Flutter extension version 3.24.0

[√] Connected device (2 available)
• Chrome (web) • chrome • web-javascript • Google Chrome 92.0.4515.107
• Edge (web) • edge • web-javascript • Microsoft Edge 91.0.864.70

! Doctor found issues in 1 category.

@no-response no-response bot removed the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Jul 23, 2021
@kavita665

This comment has been minimized.

@kavita665
Copy link
Author

kavita665 commented Jul 23, 2021

flutter run --verbose

logs
PS D:\KAVITA\flutter project\firstproject> flutter run --verbose
[  161 ms] executing: [D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%H
[  389 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%H
[    2 ms] f4abaa0735eba4dfd8f33f73363911d63931fe03
[    3 ms] executing: [D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter/] git tag --points-at f4abaa0735eba4dfd8f33f73363911d63931fe03
[ 1146 ms] Exit code 0 from: git tag --points-at f4abaa0735eba4dfd8f33f73363911d63931fe03
[    1 ms] 2.2.3
[   41 ms] executing: [D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[  183 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[    1 ms] origin/stable
[    1 ms] executing: [D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter/] git ls-remote --get-url origin
[   82 ms] Exit code 0 from: git ls-remote --get-url origin
[    1 ms] https://github.com/flutter/flutter.git
[  328 ms] executing: [D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter/] git rev-parse --abbrev-ref HEAD
[  155 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[    3 ms] stable
[  269 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[    1 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[    3 ms] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[   32 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[    4 ms] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[  237 ms] executing: C:\Android\Sdk\platform-tools\adb.exe devices -l
[  168 ms] List of devices attached
                    RZ8N90ZZXWH            device product:a50sxx model:SM_A507FN device:a50s transport_id:2
[   58 ms] C:\Android\Sdk\platform-tools\adb.exe -s RZ8N90ZZXWH shell getprop
[  153 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[   18 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[   71 ms] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[   11 ms] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[    2 ms] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[   19 ms] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[    4 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[  296 ms] Skipping pub get: version match.
[  527 ms] Generating D:\KAVITA\flutter project\firstproject\android\app\src\main\java\io\flutter\plugins\GeneratedPluginRegistrant.java
[  195 ms] ro.hardware = exynos9611
[    2 ms] ro.build.characteristics = phone
[  170 ms] Initializing file store
[   30 ms] Skipping target: gen_localizations
[   30 ms] complete
[   32 ms] Launching lib\main.dart on SM A507FN in debug mode...
[   18 ms] D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter\bin\cache\dart-sdk\bin\dart.exe --disable-dart-dev
D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter\bin\cache\artifacts\engine\windows-x64\frontend_server.dart.snapshot --sdk-root
D:\KAVITA\k\flutter_windows_2.2.3-stable\flutter\bin\cache\artifacts\engine\common\flutter_patched_sdk/ --incremental --target=flutter --debugger-module-names--experimental-emit-debug-metadata -DFLUTTER_WEB_AUTO_DETECT=true --output-dill
C:\Users\KAVITA~1\AppData\Local\Temp\flutter_tools.a8131743\flutter_tool.cd9326e9\app.dill --packages D:\KAVITA\flutter
project\firstproject\.dart_tool\package_config.json -Ddart.vm.profile=false -Ddart.vm.product=false --enable-asserts --track-widget-creation
--filesystem-scheme org-dartlang-root --initialize-from-dill build\3c113a45063dc6628e68a4111abcacad.cache.dill.track.dill
--enable-experiment=alternative-invalidation-strategy
[  134 ms] executing: C:\Android\Sdk\platform-tools\adb.exe -s RZ8N90ZZXWH shell -x logcat -v time -t 1
[   48 ms] <- compile package:firstproject/main.dart
[  794 ms] --------- beginning of main
                    07-23 16:35:54.738 D/SensorManager( 4894): TYPE_LIGHT (5): 24.000000
[   82 ms] executing: C:\Android\Sdk\platform-tools\adb.exe version
[  222 ms] Android Debug Bridge version 1.0.41
                    Version 31.0.2-7242960
                    Installed as C:\Android\Sdk\platform-tools\adb.exe
[  262 ms] executing: C:\Android\Sdk\platform-tools\adb.exe start-server
[  219 ms] Building APK
[  184 ms] Running Gradle task 'assembleDebug'...
[   60 ms] Using gradle from D:\KAVITA\flutter project\firstproject\android\gradlew.bat.
[  125 ms] executing: [D:\KAVITA\flutter project\firstproject\android/] D:\KAVITA\flutter project\firstproject\android\gradlew.bat -Pverbose=true
-Ptarget-platform=android-arm64 -Ptarget=D:\KAVITA\flutter project\firstproject\lib\main.dart -Pdart-defines=RkxVVFRFUl9XRUJfQVVUT19ERVRFQ1Q9dHJ1ZQ==
-Pdart-obfuscation=false -Ptrack-widget-creation=true -Ptree-shake-icons=false -Pfilesystem-scheme=org-dartlang-root assembleDebug
[ 37758 ms] Welcome to Gradle 6.7!
[  368 ms] Here are the highlights of this release:
[   93 ms]  - File system watching is ready for production use
[  216 ms]  - Declare the version of Java your build requires
[  123 ms]  - Java 15 support
[  102 ms] For more details see https://docs.gradle.org/6.7/release-notes.html
[ 2931 ms] Starting a Gradle Daemon, 1 incompatible and 1 stopped Daemons could not be reused, use --status for details
[ 23376 ms] FAILURE: Build failed with an exception.
[   25 ms] * What went wrong:
[   11 ms] Could not open settings generic class cache for settings file 'D:\KAVITA\flutter project\firstproject\android\settings.gradle' (C:\Users\Kavita
Singh\.gradle\caches\6.7\scripts\1fnwrr8g4rohfp291nvlxj5qe).
[  338 ms] > BUG! exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version 60
[  929 ms] * Try:
[  130 ms] 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.
[   32 ms] * Get more help at https://help.gradle.org
[  157 ms] BUILD FAILED in 1m 3s
[  494 ms] Running Gradle task 'assembleDebug'... (completed in 67.1s)
[   40 ms] Exception: Gradle task assembleDebug failed with exit code 1
[    8 ms] "flutter run" took 71,467ms.
[   50 ms] 
           #0      throwToolExit (package:flutter_tools/src/base/common.dart:10:3)
           #1      RunCommand.runCommand (package:flutter_tools/src/commands/run.dart:663:9)
           <asynchronous suspension>
           #2      FlutterCommand.run.<anonymous closure> (package:flutter_tools/src/runner/flutter_command.dart:1043:27)
           <asynchronous suspension>
           #3      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #4      CommandRunner.runCommand (package:args/command_runner.dart:196:13)
           <asynchronous suspension>
           <asynchronous suspension>
           #6      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #7      FlutterCommandRunner.runCommand (package:flutter_tools/src/runner/flutter_command_runner.dart:232:5)
           <asynchronous suspension>
           #8      run.<anonymous closure>.<anonymous closure> (package:flutter_tools/runner.dart:62:9)
           <asynchronous suspension>
           #9      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #10     main (package:flutter_tools/executable.dart:91:3)
           <asynchronous suspension>


[  342 ms] ensureAnalyticsSent: 268ms
[    8 ms] Running shutdown hooks
[  122 ms] Shutdown hooks complete
[  331 ms] exiting with code 1

@kavita665
Copy link
Author

PS D:\KAVITA\flutter project\firstproject> flutter run
Launching lib\main.dart on SM A507FN in debug mode...

FAILURE: Build failed with an exception.

  • What went wrong:
    Could not open settings generic class cache for settings file 'D:\KAVITA\flutter project\firstproject\android\settings.gradle' (C:\Users\Kavita Singh.gradle\caches\6.7\scripts\1fnwrr8g4rohfp291nvlxj5qe).

BUG! exception in phase 'semantic analysis' in source unit 'BuildScript' Unsupported class file major version 60

  • 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

BUILD FAILED in 7s
Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 16.6s
Exception: Gradle task assembleDebug failed with exit code 1

@maheshj01
Copy link
Member

maheshj01 commented Jul 23, 2021

Hi @kavita665, It looks like this issue occurs because of incompatible versions of java, Please check the solutions mentioned here.
stackoverflow: https://stackoverflow.com/questions/32900912/bug-exception-in-phase-semantic-analysis
Similar issue: exercism/support#73

Thank you.

@maheshj01 maheshj01 added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Jul 23, 2021
@TahaTesser TahaTesser removed waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds in triage Presently being triaged by the triage team labels Aug 17, 2021
@TahaTesser
Copy link
Member

Without additional information, we are unfortunately not sure how to resolve this issue.
We are therefore reluctantly going to close this bug for now.
Please don't hesitate to comment on the bug if you have any more information for us; we will reopen it right away!
Thanks for your contribution.

Could everyone who still has this problem please file a new issue with the exact description of what happens, logs, and the output of flutter doctor -v.
All system setups can be slightly different, so it's always better to open new issues and reference related issues.

@TahaTesser TahaTesser added the r: timeout Issue is closed due to author not providing the requested details in time label Aug 17, 2021
@github-actions
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 31, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
r: timeout Issue is closed due to author not providing the requested details in time
Projects
None yet
Development

No branches or pull requests

3 participants