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 cannot instantiate bean with enum inside #41

Closed
evelyne24 opened this issue Jan 29, 2018 · 4 comments
Closed

Koin cannot instantiate bean with enum inside #41

evelyne24 opened this issue Jan 29, 2018 · 4 comments

Comments

@evelyne24
Copy link

Hi,

I am getting the following error:

Caused by: org.koin.error.BeanInstanceCreationException: Can't create bean Factory[class=com.myapp.ui.register.RegisterViewModel, binds~(android.arch.lifecycle.ViewModel)] due to error :
                  	java.lang.IllegalArgumentException: Invalid data. Unsupported type: com.myapp.data.User$Status (found in field status)

Useris a data class that has an enum of type Status

Any ideas what to do?

@arnaudgiuliani
Copy link
Member

Hello,

seems it can't instantiate your bean :/ Can you give your module definition and the Kotlin code of the component?

@arnaudgiuliani
Copy link
Member

@evelyne24 Still here ?

@arnaudgiuliani
Copy link
Member

Please reopen the issue if needed.

Thanks.

@trustmub
Copy link

trustmub commented Mar 13, 2018

i am having the same challange with my project. please check it on GitHub: https://github.com/trustmub/blueprint

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

3 participants