NoBeanDefFoundException: No defenition found for ListenableWorker
See original GitHub issueDescribe the bug
Very ofter my app crashes on boot with NoBeanDefFoundException: No defenition found for ListenableWorker
My Koin Settings
startKoin {
androidContext(this@SubApplication)
androidLogger(Level.ERROR)
androidFileProperties()
workManagerFactory()
modules(listOf(
AppModules.appModule(),
NetworkModule.okHttpModule(),
NetworkModule.retrofitModule(),
NetworkModule.scarletModule(),
AppModules.repoModule(),
WorkersModule.workersModule(),
DatabaseModule.appDatabaseModule(),
ViewModelsModule.viewModelModule(),
))
}
object WorkersModule {
fun workersModule() = module {
worker { SendLocationsWorker(androidContext(), get(), get(), get(), get()) }
worker { UpdateDeviceInfoWorker(androidContext(), get(), get()) }
}
}
To Reproduce
Steps to reproduce the behavior:
I don’t know, this error appears intermittently. My workers use repositories from AppModules.repoModule()
Koin project used and used version (please complete the following information):
def koin_version = "2.2.1"
api("org.koin:koin-core:$koin_version")
api("org.koin:koin-core-ext:$koin_version")
testApi("org.koin:koin-test:$koin_version")
api("org.koin:koin-androidx-scope:$koin_version")
api("org.koin:koin-androidx-viewmodel:$koin_version")
api("org.koin:koin-androidx-fragment:$koin_version")
api("org.koin:koin-androidx-workmanager:$koin_version")
api("org.koin:koin-androidx-ext:$koin_version")
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:16 (2 by maintainers)
Top Results From Across the Web
WorkManager set up with KOIN - android - Stack Overflow
Caused by: org.koin.core.error.NoBeanDefFoundException: No definition found for class:'androidx.work.WorkerParameters'. Check your ...
Read more >Org.Koin.Core.Error.Nobeandeffoundexception. How To Fix ...
The koin test results as follows: org.koin.core.error.NoBeanDefFoundException: No definition found for 'classname ' has been found.Check your module . The koin ...
Read more >Android – Koin: NoBeanDefFoundException, Check your ...
The koin test results as follows: org.koin.core.error.NoBeanDefFoundException: No definition found for '<class_name>' has been found.
Read more >Threading in ListenableWorker - Android Developers
A ListenableWorker only signals when the work should start and stop and leaves the threading entirely up to you.
Read more >Koin: NoBeanDefFoundException, Check your module ...
[Solved]-Koin: NoBeanDefFoundException, Check your module definitions-kotlin. Search. score:16. Accepted answer. I found the issue and the mistake was the ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I have the same problem! The error appears intermittently as you said. Can you create a bug report?
still every second launch - crash