Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Koin 4.0.0 Compatibility issue with lib which used Koin 3.3.3 #2033

Open
FireHook opened this issue Oct 23, 2024 · 1 comment
Open

Koin 4.0.0 Compatibility issue with lib which used Koin 3.3.3 #2033

FireHook opened this issue Oct 23, 2024 · 1 comment

Comments

@FireHook
Copy link

FireHook commented Oct 23, 2024

Describe the bug
After changing Koin version from 3.5.6 to 4.0.0 such exception occurs:

FATAL EXCEPTION: main
                 Process: com.example.debug, PID: 12536
                 java.lang.NoSuchMethodError: No virtual method getScopes()Ljava/util/HashSet; in class Lorg/koin/core/module/Module; or its super classes (declaration of 'org.koin.core.module.Module'

The problem arises because of lib which uses Koin 3.3.3

To Reproduce
Add Koin dependency with 4.0.0 version
Add any lib which uses lower version like 3.3.3
Run Android app

Expected behavior
The app should start and Koin initialised successfully.

Koin module and version:
koin = "4.0.0"

koin-android = { module = "io.insert-koin:koin-android", version.ref = "koin" }
koin-compose = { module = "io.insert-koin:koin-androidx-compose", version.ref = "koin" }
koin-core = { module = "io.insert-koin:koin-core", version.ref = "koin" }
koin-java = { module = "io.insert-koin:koin-android-compat", version.ref = "koin" }
koin-junit4 = { module = "io.insert-koin:koin-test-junit4", version.ref = "koin" }
koin-junit5 = { module = "io.insert-koin:koin-test-junit5", version.ref = "koin" }
koin-test = { module = "io.insert-koin:koin-test", version.ref = "koin" }

@FireHook FireHook changed the title Koin 4.0.0 Compatibility issue with aar lib which used Koin 3.3.3 Koin 4.0.0 Compatibility issue with lib which used Koin 3.3.3 Oct 23, 2024
@egorikftp
Copy link

Its expected due to its major release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants