teslamotors / react-native-camera-kit

A high performance, easy to use, rock solid camera library for React Native apps.
MIT License
2.49k stars 590 forks source link

A problem occurred evaluating project ':react-native-camera-kit'. > Could not get unknown property 'kotlin_version' for object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler. #669

Open thrinath925 opened 5 months ago

thrinath925 commented 5 months ago

FAILURE: Build failed with an exception.

BUILD FAILED in 7s error Failed to install the app. Command failed with exit code 1: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081 FAILURE: Build failed with an exception. Where: Build file 'C:\Users\DELL\Desktop\React native camera module\videochat\node_modules\react-native-camera-kit\android\build.gradle' line: 23 What went wrong: A problem occurred evaluating project ':react-native-camera-kit'. > Could not get unknown property 'kotlin_version' for object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler. * 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 7s. info Run CLI with --verbose flag for more details.

solved

i don't know is it fix are not but

but for me this errors is solved by

changing a build file in node_modules\react-native-camera-kit\android\build.gradle

from

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"

to

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion"

i have changed to kotlinVersion bcoz i found that build.gradle in android\build.gradle

**kotlinVersion = "1.9.22" vibrable name is like this rather kotlin_version**

buildscript { ext { buildToolsVersion = "34.0.0" minSdkVersion = 23 compileSdkVersion = 34 targetSdkVersion = 34 ndkVersion = "26.1.10909125" kotlinVersion = "1.9.22" -------------------------------------> observe this name } repositories { google() mavenCentral() } dependencies { classpath("com.android.tools.build:gradle") classpath("com.facebook.react:react-native-gradle-plugin") classpath("org.jetbrains.kotlin:kotlin-gradle-plugin") } }

thrinath925 commented 5 months ago

can some one explain is it correct way are not

muffix200 commented 5 months ago

https://github.com/teslamotors/react-native-camera-kit/issues/511#issuecomment-1475588482