Vivek Modi
07/21/2022, 9:35 AMkotlinx.serialization compiler plugin is not applied to the module, so this annotation would not be processed. Make sure that you've setup your buildscript correctly and re-import project.
Vivek Modi
07/21/2022, 9:36 AMplugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
}
android {
compileSdk 32
defaultConfig {
applicationId "com.vivek.sportsresult"
minSdk 21
targetSdk 32
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
useSupportLibrary true
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), '<http://proguard-rules.pro|proguard-rules.pro>'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '1.8'
}
buildFeatures {
compose true
}
composeOptions {
kotlinCompilerExtensionVersion compose_version
}
packagingOptions {
resources {
excludes += '/META-INF/{AL2.0,LGPL2.1}'
}
}
}
dependencies {
implementation 'androidx.core:core-ktx:1.8.0'
implementation 'androidx.activity:activity-compose:1.5.0'
implementation "androidx.compose.material:material:$compose_version"
implementation "androidx.compose.material3:material3:$compose_material3_version"
implementation "androidx.compose.ui:ui:$compose_version"
implementation "androidx.compose.ui:ui-tooling-preview:$compose_preview_version"
implementation "androidx.compose.runtime:runtime-livedata:$compose_version"
implementation "androidx.navigation:navigation-compose:$nav_version"
debugImplementation "androidx.compose.ui:ui-tooling:$compose_preview_version"
debugImplementation "androidx.compose.compiler:compiler:$compose_ui_version"
debugImplementation "androidx.compose.ui:ui-test-manifest:$compose_version"
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
androidTestImplementation "androidx.compose.ui:ui-test-junit4:$compose_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-compose:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-runtime-ktx:$lifecycle_version"
implementation 'androidx.work:work-runtime:2.7.1'
implementation "com.google.accompanist:accompanist-systemuicontroller:0.23.0"
implementation "com.airbnb.android:lottie-compose:$lottieVersion"
implementation "io.insert-koin:koin-android:$koin_version"
implementation "io.insert-koin:koin-androidx-compose:$koin_version"
implementation "com.squareup.moshi:moshi-kotlin:$moshiVersion"
kapt "com.squareup.moshi:moshi-kotlin-codegen:$moshiVersion"
implementation "com.squareup.retrofit2:retrofit:$retrofit2_version"
implementation "com.squareup.retrofit2:converter-moshi:$retrofit2_version"
implementation "com.squareup.okhttp3:okhttp:$okhttp3_version"
implementation "com.squareup.okhttp3:logging-interceptor:$okhttp3_version"
implementation "org.jetbrains.kotlinx:kotlinx-serialization-json:1.3.3"
}
Vivek Modi
07/21/2022, 9:37 AMbuildscript {
ext {
compose_version = '1.1.1'
compose_ui_version = '1.2.0'
compose_material3_version = '1.0.0-alpha14'
compose_preview_version = '1.1.1'
koin_version = '3.2.0'
lottieVersion = '5.2.0'
nav_version = '2.5.0'
lifecycle_version = '2.5.0'
moshiVersion = '1.13.0'
retrofit2_version = '2.9.0'
okhttp3_version = '4.9.3'
kotlin_version = '1.7.10'
}
}// Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins {
id 'com.android.application' version '7.2.1' apply false
id 'com.android.library' version '7.2.1' apply false
id 'org.jetbrains.kotlin.android' version '1.6.10' apply false
}
task clean(type: Delete) {
delete rootProject.buildDir
}
mbonnin
07/21/2022, 9:37 AMplugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
id 'org.jetbrains.kotlin.plugin.serialization'
}
See https://github.com/Kotlin/kotlinx.serialization#gradleVivek Modi
07/21/2022, 9:41 AM* Exception is:
org.gradle.api.plugins.UnknownPluginException: Plugin [id: 'org.jetbrains.kotlin.plugin.serialization'] was not found in any of the following sources:
- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (plugin dependency must include a version number for this source)
Javier
07/21/2022, 9:42 AMJavier
07/21/2022, 9:42 AMplugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
id 'org.jetbrains.kotlin.plugin.serialization' version '1.7.10'
}
Javier
07/21/2022, 9:43 AM1.6.10
Vivek Modi
07/21/2022, 9:43 AMVivek Modi
07/21/2022, 9:43 AMdanL
02/19/2024, 6:22 PMdanL
02/21/2024, 3:07 PM