flutter_p2p icon indicating copy to clipboard operation
flutter_p2p copied to clipboard

Version problem with the plugin

Open sylvere36 opened this issue 5 years ago • 11 comments

I tried to integrate the plugin for a personal project, but at first I had a version problem. So I tried to update the flutter project and then it does the build. But when I launch it I get no action in return, it detects the wifi and then nothing. Please help me

sylvere36 avatar Feb 29 '20 09:02 sylvere36

Please write the output of flutter --version. Are you testing with a real device or an Android Emulator? Which Android version are you using? Please give also a minimal code example to reproduce the problem.

devtronic avatar Feb 29 '20 15:02 devtronic

here's the return of flutter --version

~/Bureau/flutterp2p$ flutter --version Flutter 1.12.13+hotfix.8 • channel stable • https://github.com/flutter/flutter.git Framework • revision 0b8abb4724 (il y a 3 semaines) • 2020-02-11 11:44:36 -0800 Engine • revision e1e6ced81d Tools • Dart 2.7.0

And this is what I get when I run the build.

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_p2p' -> org.jetbrains.kotlin:kotlin-gradle-plugin:1.2.71

  • 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 30s Gradle task assembleDebug failed with exit code 1 Exited (sigterm)

sylvere36 avatar Feb 29 '20 17:02 sylvere36

And when I put in the requested version, it doesn't play either.

sylvere36 avatar Feb 29 '20 17:02 sylvere36

Sorry for the delay. I'll take a look on that this week

devtronic avatar Mar 02 '20 08:03 devtronic

All right. Thanks for looking into it.

sylvere36 avatar Mar 02 '20 09:03 sylvere36

What happen with this bug? I wanted to give it a try but got this same error.

I was searching for fix and maybe you can try this: https://stackoverflow.com/a/54858719/3579284

p.s. Can this be tested on two different emulators?

SteffNite avatar Mar 30 '20 13:03 SteffNite

I'm sorry but I'm busy AF at the moment. If anyone will try to fix this, PRs are welcome.

@SteffNite I didn't try it on emulators so I can not say if it would work

devtronic avatar Mar 31 '20 07:03 devtronic

This error is fixed on PR

godilite avatar May 14 '20 04:05 godilite

There is no version solving error but another problem with the MissingPluginException as per below . Unhandled Exception: MissingPluginException(No implementation found for method isLocationPermissionGranted on channel de.mintware.flutter_p2p/flutter_p2p)

sohitEngg avatar Jun 04 '20 12:06 sohitEngg

Hey! I am getting this error and can't find my way around it. I did go through StackOverflow but the fixes didn't work for me.

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_p2p' -> org.jetbrains.kotlin:kotlin-gradle-plugin:1.2.71

  • 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 12s Exception: Gradle task assembleDebug failed with exit code 1

medhak16 avatar Jul 05 '20 08:07 medhak16

If anyone is still looking for a workaround (not a fix):

Downgrade the com.android.tools.build:gradle: to <flutter_p2p plugin's gradle version>

In my case it was: com.android.tools.build:gradle:3.2.1

This can be found in android/build.gradle file

buildscript {
    ext.kotlin_version = '1.3.50'
    repositories {
        google()
        jcenter()
    }

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

coderider007 avatar Sep 06 '20 13:09 coderider007