I'd like to be able to work on my project offline. So I disable offline mode, press the "sync project with gradle files" button, then enable offline mode and try to build. However, every time I do, I get the error:
FAILURE: Build failed with an exception.
*What went wrong:
Could not determine the dependencies of task ':app:compileDebugRenderscript'.
> Could not resolve all task dependencies for configuration ':app:debugCompileClasspath'.
> Could not resolve androidx.fragment:fragment:[1.2.0].
Required by
project :app > androidx.fragment:fragment-ktx:1.2.0
> No cached version listing for androidx.fragment:fragment:[1.2.0] available for offline mode.
> No cached version listing for androidx.fragment:fragment:[1.2.0] available for offline mode.
I've also tried invalidate cache/restart and then gradle sync before enabling offline mode, with the same result.
I'm running Android Studio 3.6.3
gradle-wrapper.properties contains the fololowing:
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-all.zip
How can I make androidx.fragment:fragment available for offline mode?