Environments
- M1 Mac pro 14
- VSCode
- Flutter 3.3.8
- Galaxy A52 (SM A525F)
Error Message
FAILURE: Build failed with an exception. * Where: Build file '/Users/jaewonlee/Desktop/milkflutter/android/app/build.gradle' line: 69 * What went wrong: A problem occurred evaluating project ':app'. > path may not be null or empty string. path='null' * 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 570ms Running Gradle task 'assembleDebug'... 1,213ms Exception: Gradle task assembleDebug failed with exit code 1
문제 상황
안드로이드 실 기기를 연결하여 flutter run
으로 앱 디버깅을 하려고 했을 때, 빌드가 되지 않는 현상
해결
* Where: Build file '/Users/jaewonlee/Desktop/milkflutter/android/app/build.gradle' line: 69
에서 쓰여 있듯, android > app > build.gradle
파일에서
signingConfigs { release { keyAlias keystoreProperties['keyAlias'] keyPassword keystoreProperties['keyPassword'] storeFile file(keystoreProperties['storeFile']) storePassword keystoreProperties['storePassword'] } } buildTypes { release { // TODO: Add your own signing config for the release build. // Signing with the debug keys for now, so `flutter run --release` works. signingConfig signingConfigs.release } }
이 부분을 comment out (주석처리 or 삭제) 해주면 해결된다.
Reference