I have found a solution I don't know if it work really but a least it 
compile and allow me to do my work...
Just copy paste what's inside your base module "build.gradle" inside your 
feature module "build.gradle"

basically,

dependencies {

    [...]

    implementation 'android.arch.lifecycle:runtime:1.0.0'
    implementation 'android.arch.lifecycle:extensions:1.0.0-alpha9-1'
    annotationProcessor 'android.arch.lifecycle:compiler:1.0.0-alpha9-1'
    implementation 'android.arch.persistence.room:runtime:1.0.0-alpha9-1'
    annotationProcessor 'android.arch.persistence.room:compiler:1.0.0-alpha9-1'

}


If you have this in your base build.gradle, copy paste it in your feature 
module (and potentially all other feature...).


Le jeudi 21 septembre 2017 16:20:04 UTC+2, Romain Graillot a écrit :
>
> Hello,
>
> I am using the Room library in the base module of our Instant app project.
> Whenever I try to compile one "feature" module of the app, an error happen 
> at compile time:
>
> "*error: cannot access RoomDatabase*"
> followed by
> "*class file for android.arch.persistence.room.RoomDatabase not found*"
>
> The only answer I've found so far is here: 
> https://medium.com/@pinakin.k.kansara/hi-florina-thank-you-for-the-detailed-article-84d8e67ac509
>
> It is true ? How can I do to implement local storage in the app using room 
> in my base module ? Did I have to rewrite all from scratch to avoid using 
> Room  ?
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/android-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-developers/0006eca2-215d-4257-9bca-45e93daad834%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to