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

java.lang.NoSuchMethodException: no.nordicsemi.android.common.permissions.ble.viewmodel.PermissionViewModel.<init> #134

Open
davehorner opened this issue Mar 23, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@davehorner
Copy link

both app_server and app_client build but crash when run app_server I get:

2024-03-23 08:12:18.188 32625-32625 AndroidRuntime          no....android.kotlin.ble.app.server  E  FATAL EXCEPTION: main
                                                                                                    Process: no.nordicsemi.android.kotlin.ble.app.server, PID: 32625
                                                                                                    java.lang.RuntimeException: Cannot create an instance of class no.nordicsemi.android.common.permissions.ble.viewmodel.PermissionViewModel
                                                                                                    	at androidx.lifecycle.ViewModelProvider$NewInstanceFactory.create(ViewModelProvider.kt:201)
                                                                                                    Caused by: java.lang.NoSuchMethodException: no.nordicsemi.android.common.permissions.ble.viewmodel.PermissionViewModel.<init> []
                                                                                                    	at java.lang.Class.getConstructor0(Class.java:3325)
                                                                                                    	at java.lang.Class.getDeclaredConstructor(Class.java:3063)
                                                                                                    	at 

is there something I should do before building I'm missing?

@philips77
Copy link
Member

I got the same issue. I hope it will work after releasing new versions, as what fixed it for me was using the common library locally instead of from Maven Central. I still don't know why it was happening.

@philips77 philips77 added the bug Something isn't working label Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants