Open dhruvikapdiwebiots opened 4 months ago
i also have same issue try to remove pub caches in your local path
i also facing the same issue
i think it is not working for kotlin 1.9.0
01.The issue is this package is not working for kotlin 1.9.0 02.Specialy when we use with flutter stripe package we can not use current version of this package. 03.after i got a error in a development i tested this package seperately.
have the same issue, any fixes, or updates? thx
Yes.
@SriFromFindStoneAge Does version 7.0.4 work for you even with the Stripe package? I've been having the the same problem. I tried the example project and a new flutter project with the nb_utils package and both worked. However, as soon as I try to use nb_utils (even version 7.0.4) with my actual app, I get the jvm target compatibility error again.
same
I simply got rid of this package because of this issue
Same error here, does anyone have any suggestion?
* What went wrong:
Execution failed for task ':nb_utils:compileReleaseKotlin'.
> Inconsistent JVM-target compatibility detected for tasks 'compileReleaseJavaWithJavac' (1.8) and 'compileReleaseKotlin' (17).
Consider using JVM Toolchain: https://kotl.in/gradle/jvm/toolchain
Learn more about JVM-target validation: https://kotl.in/gradle/jvm/target-validation
I try to change android compileOption to 17 but not work.
android {
namespace "my.app"
compileSdk 34 // flutter.compileSdkVersion
ndkVersion flutter.ndkVersion
compileOptions {
sourceCompatibility 17
targetCompatibility 17
}
kotlinOptions {
jvmTarget = '17'
}
....
}
Also try to run flutter build --jdk-dir "/path/to/jdk18"
still error Inconsistent between 1.8 and 18.
Could you please confirm whether you are using the stripe package alongside the nb_utils package?
If you ask me, I dont use Stripe library. I rollback to gradle 7.6.3, plugin 1.9.20, delete the hosted/pub.get folder in C drive. Now it can compile with bunk of incompatible warning and error.
I added a fix and raised a PR. We will have to wait for the approval and if any one is blocked with this issue then you can directly add my repo to your pubspec.yml Replace :
dependencies:
nb_utils: ^7.0.4
With
dependencies:
nb_utils:
git: https://github.com/Rissmon/nb_utils
Once PR is merged we can revert the pubspec change.
any update? i still got the same issue
i have applied fix in this Pull Request #60 . Some one please confirm this
Screenshot of example app
Execution failed for task ':nb_utils:compileDebugKotlin'.