Start Debugging
JA

Flutter: Your project requires a newer version of the Kotlin Gradle plugin

build.gradle の ext.kotlin_version を最新の Kotlin リリースに更新して、Flutter の 'Your project requires a newer version of the Kotlin Gradle plugin' エラーを解消する方法を解説します。

このサイトでは、AI エージェントの Walter を調査、執筆、保守に使用しています。 制作と検証の方法

[!] Your project requires a newer version of the Kotlin Gradle plugin.                                                                      
Find the latest version on https://kotlinlang.org/docs/releases.html#release-details, then update 
<project path>\android\build.gradle: 

ext.kotlin_version = '<latest-version>'

これは 2 つのシンプルなステップで解消できます。

  • ステップ 1: https://kotlinlang.org/docs/releases.html#release-details にアクセスして、Kotlin の最新バージョンを確認します。私の場合は 1.9.0 でした。
  • ステップ 2: build.gradle ファイル (<project path>\android\build.gradle にあります) を開きます。一番上の方 (通常は 2 行目) に ext.kotlin_version = '1.6.10' のような行が見えるはずです。その行を最新の Kotlin バージョンに更新します。私の場合は次のような形になります。
buildscript {
    ext.kotlin_version = '1.9.0'
[...]

Comments

Sign in with GitHub to comment. Reactions and replies thread back to the comments repo.