ponnamkarthik / FlutterRtmpPlublisher

A Flutter Plugins that helps you to brodcast Live via RTMP right from your flutter application
Other
53 stars 44 forks source link

Error: Kotlin Gradle plugin version #3

Open dekdoijaidee opened 4 years ago

dekdoijaidee commented 4 years ago

Hi

I use your lib and found error when build my app

FAILURE: Build failed with an exception.

  • What went wrong: The Android Gradle plugin supports only Kotlin Gradle plugin version 1.3.10 and higher. The following dependencies do not satisfy the required version: project ':flutter_rtmp_publisher' -> org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.0

What should I do?

Thank you

TejaDroid commented 4 years ago

You have to degrade your Kotlin Gradle Version : 1.3.0, because flutter_rtmp_publisher using gradle version of 1.3.0.

Vercjames commented 4 years ago

Howdy! forgive me but I must be missing something because just changing build.gradle ext.kotlin_version = '1.3.50' to "1.3.0" doesn't fix the issue. Can you please be more specific on how to downgrade property. Thanks.

I tried a flutter clean but still got the same error

Vercjames commented 4 years ago

resolved, changing minSdkVersion 16 to 21 and copying this packages Buildscript worked.

selvakumardreams commented 4 years ago

@Vercjames , I too have the same issue. I have changed minSdkVersion 16 to 21. Still, I am getting the error. Could you detail copying these packages build scripts mean?

Vercjames commented 4 years ago

Hit me up with the error message you are getting. Additionally after changing the 16 to 21 and then downgrading the Grable Version, I ran a Flutter Clean.

android/build.gradle

buildscript {
    ext.kotlin_version = '1.3.0'
    repositories {
        google()
        jcenter()
        maven { url 'https://jitpack.io' }
    }

    dependencies {
        classpath 'com.android.tools.build:gradle:3.2.1'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

allprojects {
    repositories {
        google()
        jcenter()
    }
}

rootProject.buildDir = '../build'
subprojects {
    project.buildDir = "${rootProject.buildDir}/${project.name}"
}
subprojects {
    project.evaluationDependsOn(':app')
}

task clean(type: Delete) {
    delete rootProject.buildDir
}
selvakumardreams commented 4 years ago

Thanks @Vercjames its resolved

abheet-98 commented 4 years ago

@Vercjames my issue is not getting resolved by doing these three things

Hit me up with the error message you are getting. Additionally after changing the 16 to 21 and then downgrading the Grable Version, I ran a Flutter Clean.

android/build.gradle

buildscript {
    ext.kotlin_version = '1.3.0'
    repositories {
        google()
        jcenter()
        maven { url 'https://jitpack.io' }
    }

    dependencies {
        classpath 'com.android.tools.build:gradle:3.2.1'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

allprojects {
    repositories {
        google()
        jcenter()
    }
}

rootProject.buildDir = '../build'
subprojects {
    project.buildDir = "${rootProject.buildDir}/${project.name}"
}
subprojects {
    project.evaluationDependsOn(':app')
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

Could u explain me in some detail?

Vercjames commented 4 years ago

Can you provide me some context kind sir. an error message perhaps. I assume you are trying to set this all up in a new flutter project. Also I used windows to compile my application, if you are MacOS something may be different with the pod installation.

abheet-98 commented 4 years ago

@Vercjames Yes I'm trying this all in a new flutter project and working on windows. The error message is same: FAILURE: Build failed with an exception.

I have set minsdk in app build.gradle to 21 and done flutter clean as well. If u could help me with how to downgrade the gradle version that will suffice I think.

Vercjames commented 4 years ago

Peculiar - since the provided script should have downgraded gradle for you. but rather than leaving you hanging I made a video to hopefully put this thread to bed. hopefully this solves the issue.

https://www.youtube.com/watch?v=3fVS8dVMftY

abheet-98 commented 4 years ago

@Vercjames Thank you for the video but now there are more issues arising. Actually I'm also using the camera plugin which I think is giving error.

**FAILURE: Build failed with an exception.

BUILD FAILED in 32s Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 33.6s The built failed likely due to AndroidX incompatibilities in a plugin. The tool is about to try using Jetfier to solve the incompatibility. Building plugin camera... Running Gradle task 'assembleAarRelease'...
Running Gradle task 'assembleAarRelease'... Done 4.4s

FAILURE: Build failed with an exception.

BUILD FAILED in 3s

The plugin camera could not be built due to the issue above.**

odejinmi commented 3 years ago

Hit me up with the error message you are getting. Additionally after changing the 16 to 21 and then downgrading the Grable Version, I ran a Flutter Clean.

android/build.gradle

buildscript {
    ext.kotlin_version = '1.3.0'
    repositories {
        google()
        jcenter()
        maven { url 'https://jitpack.io' }
    }

    dependencies {
        classpath 'com.android.tools.build:gradle:3.2.1'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

allprojects {
    repositories {
        google()
        jcenter()
    }
}

rootProject.buildDir = '../build'
subprojects {
    project.buildDir = "${rootProject.buildDir}/${project.name}"
}
subprojects {
    project.evaluationDependsOn(':app')
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

after downgrading this the error I'm having

FAILURE: Build failed with an exception.