Monday, April 22, 2024
HomeiOS Developmentandroid - (lacking buildfscript{ } ). Module was compiled with an incompatible...

android – (lacking buildfscript{ } ). Module was compiled with an incompatible model of Kotlin. The binary model of metadata 1.9.0,anticipated model 1.7.1


Right here the debug console provides a solution to mounted the issue to alter

ext.kotlin_version = '<latest-version>

so i attempted to alter the most recent kotlin model,as i see the ohter answer

the road ext.kotlin_version = '<latest-version> embody in buildscript{ ... }

 buildscript {
    ext.kotlin_version = '1.9.23' // Change right here
    repositories {
        google()
        jcenter()
    }

    dependencies {
        classpath 'com.android.instruments.construct:gradle:4.1.0'
       // classpath 'com.google.gms:google-services:4.4.1'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

However in my challenge stage construct.gridle haven’t any buildscript{..}

construct.gradle (my challenge)

allprojects {
    repositories {
        google()
        mavenCentral()
    }
}

rootProject.buildDir="../construct"
subprojects {
    challenge.buildDir = "${rootProject.buildDir}/${challenge.title}"
}
subprojects {
    challenge.evaluationDependsOn(':app')
}

duties.register("clear", Delete) {
    delete rootProject.buildDir
}

subsequently i attempted one other answer the place i modified the model in plugin of settings.gradle

settings.gradle

pluginManagement {
    def flutterSdkPath = {
        def properties = new Properties()
        file("native.properties").withInputStream { properties.load(it) }
        def flutterSdkPath = properties.getProperty("flutter.sdk")
        assert flutterSdkPath != null, "flutter.sdk not set in native.properties"
        return flutterSdkPath
    }
    settings.ext.flutterSdkPath = flutterSdkPath()

    includeBuild("${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle")

    repositories {
        google()
        mavenCentral()
        gradlePluginPortal()
    }
}

plugins {
    id "dev.flutter.flutter-plugin-loader" model "1.0.0"
    id "com.android.utility" model "7.3.0" apply false
    id "org.jetbrains.kotlin.android" model "1.9.22" apply false 
    id "com.google.gms.google-services" model "4.4.1" apply false
}

after that the debug console and system display screen – debug console and system

Are you able to assist me with an answer?



Supply hyperlink

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments