brian
03/07/2023, 12:25 PMbuild.gradle.kts
Cannot access 'java.lang.Object' which is a supertype of 'org.gradle.api.artifacts.dsl.DependencyHandler'. Check your module classpath for missing or conflicting dependencies
brian
03/07/2023, 12:26 PMAndre Theilacker
03/07/2023, 4:25 PMchanjungskim
03/09/2023, 3:51 AManshulnigam111
03/09/2023, 7:03 AMNav
03/09/2023, 8:16 AMTimur Abdyraev
03/09/2023, 8:50 AMDokka
for documenting my Android Application and I want to know how to exclude inherited members from class. `supressInheritedMembers`doesn't work.
My Gradle Task:
tasks.dokkaHtmlMultiModule {
moduleName.set("")
moduleVersion.set(appConfig.versionName)
suppressInheritedMembers.set(true)
pluginConfiguration<DokkaBase, DokkaBaseConfiguration> {
separateInheritedMembers = true
customAssets = listOf(file("assets/tez-sat.svg"))
footerMessage =
"Tez Sat™ Technical Documentation © ${java.time.Year.now().value} Copyright."
customStyleSheets =
listOf(file("$projectDir/logo-style.css"), file("$projectDir/logo-styles.css"))
}
}
Keval Kanpariya
03/09/2023, 11:49 AMTask :app:hiltJavaCompileDebug
error: ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.SingletonC' because 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' could not be resolved.
Dependency trace:
=> element (CLASS): androidx.hilt.lifecycle.ViewModelFactoryModules.ActivityModule
ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.SingletonC' because 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' could not be resolved.
=> element (METHOD): provideFactory(android.app.Activity,android.app.Application,java.util.Map<java.lang.String,javax.inject.Provider<androidx.hilt.lifecycle.ViewModelAssistedFactory<? extends androidx.lifecycle.ViewModel>>>)
=> annotation: @dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory
=> type (ERROR annotation type): dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory
If type 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' is a generated type, check above for compilation errors that may have prevented the type from being generated. Otherwise, ensure that type 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' is on your classpath.
error: ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.ActivityRetainedC' because 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' could not be resolved.
Dependency trace:
=> element (CLASS): androidx.hilt.lifecycle.ViewModelFactoryModules.ActivityModule
=> element (METHOD): provideFactory(android.app.Activity,android.app.Application,java.util.Map<java.lang.String,javax.inject.Provider<androidx.hilt.lifecycle.ViewModelAssistedFactory<? extends androidx.lifecycle.ViewModel>>>)
ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.ActivityRetainedC' because 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' could not be resolved.
=> annotation: @dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory
=> type (ERROR annotation type): dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory
If type 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' is a generated type, check above for compilation errors that may have prevented the type from being generated. Otherwise, ensure that type 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' is on your classpath.
ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.ActivityC' because 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' could not be resolved.
error: ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.ActivityC' because 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' could not be resolved.
Dependency trace:
=> element (CLASS): androidx.hilt.lifecycle.ViewModelFactoryModules.ActivityModule
=> element (METHOD): provideFactory(android.app.Activity,android.app.Application,java.util.Map<java.lang.String,javax.inject.Provider<androidx.hilt.lifecycle.ViewModelAssistedFactory<? extends androidx.lifecycle.ViewModel>>>)
=> annotation: @dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory
=> type (ERROR annotation type): dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory
If type 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' is a generated type, check above for compilation errors that may have prevented the type from being generated. Otherwise, ensure that type 'dagger.hilt.android.internal.lifecycle.DefaultActivityViewModelFactory' is on your classpath.
error: ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.FragmentC' because 'dagger.hilt.android.internal.lifecycle.DefaultFragmentViewModelFactory' could not be resolved.
Dependency trace:
=> element (CLASS): androidx.hilt.lifecycle.ViewModelFactoryModules.FragmentModule
ComponentProcessingStep was unable to process 'dev.kevalkanpariya.featuretesteduco.EduCoApplication_HiltComponents.FragmentC' because 'dagger.hilt.android.internal.lifecycle.DefaultFragmentViewModelFactory' could not be resolved.
=> element (METHOD): provideFactory(androidx.fragment.app.Fragment,android.app.Application,java.util.Map<java.lang.String,javax.inject.Provider<androidx.hilt.lifecycle.ViewModelAssistedFactory<? extends androidx.lifecycle.ViewModel>>>)
=> annotation: @dagger.hilt.android.internal.lifecycle.DefaultFragmentViewModelFactory
=> type (ERROR annotation type): dagger.hilt.android.internal.lifecycle.DefaultFragmentViewModelFactory
If type 'dagger.hilt.android.internal.lifecycle.DefaultFragmentViewModelFactory' is a generated type, check above for compilation errors that may have prevented the type from being generated. Otherwise, ensure that type 'dagger.hilt.android.internal.lifecycle.DefaultFragmentViewModelFactory' is on your classpath.
4 errors
Dagger hilt version : 2.42
Kotlin Version: 1.7.0
Gradle Version: 7.4.1
What's causes this error?Pablo
03/10/2023, 7:44 AMEspresso
tests?Breaker ACT
03/10/2023, 10:13 AMZaki Shaikh
03/10/2023, 10:14 AMfaisalahmed
03/10/2023, 11:20 AMmutableStateListOf()
.
add and remove on the list triggers succesful recompositions of the specific item, but changing the value at any index of this list does not trigger any recomposition. Been scratching my head at this. My LazyColumn
is keyed to a unique id
coming in the data as well. So I am wondering what might be going wrong. Following is an example. Inside ViewModel
val list = mutableStateListOf<Messages>()
fun onMessageChanged(newMessage: Message) {
val index = list.indexOf(newMessage) // returns correct index
list[index] = newMessage // does not trigger recomposition
}
itnoles
03/11/2023, 2:34 AMSlackbot
03/11/2023, 8:17 AMBhupesh Chouhan
03/13/2023, 6:37 AMRyan Mentley
03/13/2023, 7:36 AMJustin Xu
03/14/2023, 2:26 AM(context as Activity).finish()
inside my fragment, but that doesn't seem to be right.chanjungskim
03/14/2023, 3:48 AMTarek Mohamed
03/14/2023, 9:21 AMPrasad Vennam
03/14/2023, 6:16 PMDerek Alves
03/15/2023, 12:15 AMGuys, has anyone gone through this?
FragmentContainerView must be within a FragmentActivity to use android:name="com.example.meditation_ui.MessageFragment"
Colton Idle
03/15/2023, 3:42 AMWith Universe
03/15/2023, 9:47 AMWith Universe
03/15/2023, 9:49 AMMichael Vandendriessche
03/15/2023, 10:49 AM@JsonClass(generateAdapter = true)
data class Command(
val cmd: String
){
companion object{
val firstCommand = Command("command1")
val secondCommand = Command("command2")
val thirdCommand = Command("command3")
}
}
I have a data class which is parsed to/from json by Moshi.
some Commands contain a string which needs to be calculated but in some cases it can be a static string.
I could make an enum with the default command strings or a sealed class with objects with a Command value. But this one seems more practical to use Command.firstCommand
and it saves me an extra file/class with default values.
I don't see a problem with it other than it looks a bit strange.KotlinLeaner
03/15/2023, 11:26 AMdelay
in my launch function. I always use xxxL
value for delay
. Is there any function to convert seconds
, minutes
& hours
. For example
/ For 30 second
delay(30)
// For 1 minute
delay(1)
// For 2 Hour
delay(2)
It's so much confusing to multiple by value. ThanksFabio Berta
03/15/2023, 2:06 PMby
syntax? All solutions I found so far rely on runtime exceptions which I would like to avoid. Any ideas?vesp
03/15/2023, 8:26 PMfun Float.convertDpToPx(): Float = this * Resources.getSystem().displayMetrics.density
What is that technique called where its structured fun <TYPE>.<FUNCTION_NAME>(...).....
. Is this called a class extension?Sandeep Kulkarni
03/16/2023, 7:18 AMDanish Ansari
03/16/2023, 1:48 PM@kotlinx.parcelize.Parcelize
and @kotlinx.android.parcel.Parcelize
annotation? They have exact same documentation and both come from kotlin-parcelize
gradle plugin.
Android Studio warns that later one is deprecated but I can clearly see that kotlinx.android.parcel.Parcelize.kt
is not annotated with @Deprecated
, so where is the warning coming from?Danish Ansari
03/16/2023, 1:48 PM@kotlinx.parcelize.Parcelize
and @kotlinx.android.parcel.Parcelize
annotation? They have exact same documentation and both come from kotlin-parcelize
gradle plugin.
Android Studio warns that later one is deprecated but I can clearly see that kotlinx.android.parcel.Parcelize.kt
is not annotated with @Deprecated
, so where is the warning coming from?zsmb
03/16/2023, 3:32 PMDanish Ansari
03/16/2023, 3:40 PM