[Flutter] 자주 발견되는 에러 Android - feat.minSdkVersion

🧐Luka.Kim.Dev·2023년 6월 30일
0
FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:processDebugMainManifest'.
> Manifest merger failed : uses-sdk:minSdkVersion 16 cannot be smaller than version 19 declared in library [:webview_flutter_android] /Users/debug/AndroidManifest.xml as the library might be using APIs not available in 16
  	Suggestion: use a compatible library with a minSdk of at most 16,
  		or increase this project's minSdk version to at least 19,
  		or use tools:overrideLibrary="io.flutter.plugins.webviewflutter" to force usage (may lead to runtime failures)

* 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 17s

┌─ Flutter Fix ─────────────────────────────────────────────────────────────────────────────────┐
│ The plugin webview_flutter_android requires a higher Android SDK version.                     │
│ Fix this issue by adding the following to the file                                            │
│ /Users/android/app/build.gradle:     │
│ android {                                                                                     │
│   defaultConfig {                                                                             │
│     minSdkVersion 19                                                                          │
│   }                                                                                           │
│ }                                                                                             │
│                                                                                               │
│ Following this change, your app will not be available to users running Android SDKs below 19. │
│ Consider searching for a version of this plugin that supports these lower versions of the     │
│ Android SDK instead.                                                                          │
│ For more information, see:                                                                    │
│ https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration          │
└───────────────────────────────────────────────────────────────────────────────────────────────┘
Exception: Gradle task assembleDebug failed with exit code 1

너무 자주 나온다.

대충 봐도 눈에 확 들어온다.
"minSdkVersion 19" 가 문제가 있나보다.

🤪

android / app / src / build.gradle 안에들어가서
minSdkVersion을 살펴보자.

위의 코드와 달리 숫자로 안되어 있다?
그럼 19로 바꿔봐야지.
친절도 하셔라.

해결완료 😆

profile
코드가 내 마음을 읽어서 자동으로 작성되는 그날이 하루 빨리 오길..🧑🏻‍💻

0개의 댓글