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

no such table in [com.android.tools.build:gradle:2.0.0-beta6] #536

Closed
s90304a123 opened this issue Mar 3, 2016 · 25 comments
Closed

no such table in [com.android.tools.build:gradle:2.0.0-beta6] #536

s90304a123 opened this issue Mar 3, 2016 · 25 comments

Comments

@s90304a123
Copy link

I found in [com.android.tools.build:gradle:2.0.0-beta6]
always get No such table error...
I trace the source to here class : com.orm.util.ReflectionUtil
getAllClasses method always return 0 length
Could you fix this bug?

@JonatanSalas
Copy link
Collaborator

@s90304a123 show me your model classes! Have they an empty constructor? How is defined the AndroidManifest metadata?

@s90304a123
Copy link
Author

@jonisaa I'm pretty sure model classes have an empty constructor. And my AndroidManifest metadata like this :

 <meta-data  android:name="DATABASE"   android:value="ccv.db"/>
 <meta-data  android:name="VERSION"  android:value="3"/>
 <meta-data android:name="QUERY_LOG" android:value="true"/>
 <meta-data  android:name="DOMAIN_PACKAGE_NAME"  android:value="db"/>

I change android plugin version to : com.android.tools.build:gradle:1.5.0
and grandle version to: 2.6
does not appear this bug

@JonatanSalas
Copy link
Collaborator

@s90304a123 When you where working with the plugin version 1.5.0 of Gradle, your code works correctly?

@s90304a123
Copy link
Author

@jonisaa Yes, when I downgrade to 1.5 version of com.android.tools.build:gradle, everything is perfect.
I guess the problem is Reflection.

@JonatanSalas
Copy link
Collaborator

@s90304a123 It's strange, because I have a project with the latest gradle beta plugin working fine. When working with gradle beta plugin, which version of gradle do you use? I work with gradle 2.10 distribution.

@mikecole20
Copy link

I'm also seeing this issue. Sugar was working fine before trying to upgrade tools/gradle but gives an error finding USER Table after upgrading.

Old Settings
classpath 'com.android.tools.build:gradle:1.3.1'
distributionUrl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip
New Settings
classpath 'com.android.tools.build:gradle:2.0.0-beta6'
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip.

@mikecole20
Copy link

I realized that I'm using Sugar 1.3. I'm in the process of updating to 1.5. I'll report back with results.

@mikecole20
Copy link

Ok, I have confirmed this is an issue with Sugar 1.5 as well.

@sibelius
Copy link
Contributor

sibelius commented Mar 9, 2016

@mikecole20 could you share your logs?

could you create a repo on github with this problem? so we can reproduce it?

@WoogieNoogie
Copy link

I've run into a similar problem, but it's only an issue if I build from Android Studio - everything is fine if I build from command line. Not sure if there's anything else I can contribute.

@ed-george
Copy link

I also experienced this issue (see #542) and found that disabling the experimental 'Instant Run' feature resolved it.

Edit: To be a little more specific, this issue only occurred after updating Android Studio from 2.0-beta4 to 2.0-beta6.

@WoogieNoogie
Copy link

Thanks for the tip @ed-george - disabling instant run did fix it. I've also updated to 2.1.0-alpha1 and this fix works there as well.

@ed-george
Copy link

No problem @WoogieNoogie, for the meantime I would suggest that disabling the feature is the current workaround and should be documented as such.

Currently in which channel is 2.1.0-alpha1 available? I will try to verify that too.

@WoogieNoogie
Copy link

It's up on Jcenter, you can use it without updating Android Studio, but the version of AS that forces the update to it is in the Canary channel.

@mikecole20
Copy link

I've also noticed it's only a problem after a clean install. If you have a working build on the device/emulator built with 1.x.x and then upgrade to 2.x.x, it will continue to work until you uninstall.

@ed-george
Copy link

@mikecole20 I can confirm that the issue only occurred once the app was uninstalled, however the AS version migration I had problems with was from 2.0.0-beta4 to 2.0.0-beta6. 2.0.0-beta4 seemed to work as expected for me.

@rkj1515
Copy link

rkj1515 commented Mar 11, 2016

Android Instant run is a problem. disable it and remove your build folder.
Do a fresh install and all set

@firaskafri
Copy link
Contributor

Any updates on this issue?

@sibelius
Copy link
Contributor

use sugar 1.5

@firaskafri
Copy link
Contributor

1.5 didn't solve the InstantRun issue

@sibelius
Copy link
Contributor

have you guys added the following information in the manifest http://satyan.github.io/sugar/getting-started.html

and in the Application?

@firaskafri
Copy link
Contributor

@sibeliusseraphini yes definitely, I didn't just start using SugarORM

@firaskafri
Copy link
Contributor

Instant Run now works #564

@sibelius
Copy link
Contributor

sibelius commented Apr 5, 2016

fixed with #564 @firasalkafri

@sibelius sibelius closed this as completed Apr 5, 2016
@davidruizdiaz
Copy link

gracias @ ed-george me ayudó mucho

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

9 participants