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

Class does not have primary key #12

Open
bkjbkjbnkj687698698 opened this issue Mar 18, 2015 · 3 comments
Open

Class does not have primary key #12

bkjbkjbnkj687698698 opened this issue Mar 18, 2015 · 3 comments

Comments

@bkjbkjbnkj687698698
Copy link

Everything was working fine before i started using Proguard..I am getting exception-

Class class mz.peoplecloudlabs.apps.a.b.g does not have a primary key

How can i assign primary key to object class as tables are created automatically from object classes?

@casidiablo
Copy link
Owner

Try excluding the model classes from the proguard obfuscation.

@bkjbkjbnkj687698698
Copy link
Author

okay i did that.but now its showing exception-

java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType
at com.codeslap.persistence.SqliteAdapterImpl.getSqlInsertForChildrenOf(Unknown Source)
at com.codeslap.persistence.SqliteAdapterImpl.getSqlStatement(Unknown Source)
at com.codeslap.persistence.SqliteAdapterImpl.store(Unknown Source)
at com.codeslap.persistence.SqliteAdapterImpl.store(Unknown Source)

for storing data in database while its working fine if i disable proguard..i added following statements to exclude library files from proguard obfuscation-
-keep class com.codeslap.persistence.* {;}
-keep interface com.codeslap.persistence.
* {
;}

@casidiablo
Copy link
Owner

Did you also exclude the classes you are persisting?

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