question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support com.android.feature plugin

See original GitHub issue

Android Studio 3.0 introduced com.android.feature plugin. Because Realm explicitly checks for the existence of com.android.application or com.android.library plugins, applying realm-android in a feature causes an exception.

See the following line at Realm.groovy:

https://github.com/realm/realm-java/blob/7dbacb438f8f1130155eacf06347fce703c8f1a8/gradle-plugin/src/main/groovy/io/realm/gradle/Realm.groovy#L34

void apply(Project project) {
    // Make sure the project is either an Android application or library
    def isAndroidApp = project.plugins.withType(AppPlugin)
    def isAndroidLib = project.plugins.withType(LibraryPlugin)
    if (!isAndroidApp && !isAndroidLib) {
        throw new GradleException("'com.android.application' or 'com.android.library' plugin required.")
}

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:5
  • Comments:11 (8 by maintainers)

github_iconTop GitHub Comments

3reactions
phillipaocommented, Oct 17, 2017

ABI splits are now supported: https://android-developers.googleblog.com/2017/10/introducing-android-instant-apps-sdk-11.html?m=1. We’re happy to offer any support in using the feature.

2reactions
Zhuindencommented, Jun 21, 2017

And how to fit in the 4 MB APK size limit

Read more comments on GitHub >

github_iconTop Results From Across the Web

Migrate your instant app to support Android App Bundles
Migrate your instant app to support Android App Bundles ... If you're still using the deprecated Feature Android Gradle plugin ( com.android.
Read more >
Plugin with id 'com.android.feature' not found. Android
Requirements for instant app in build.gradle file: apply plugin: 'com.android.feature'; baseFeature = true; remove = applicationId "com.example ...
Read more >
A simpler experience for instant apps - Android Developers Blog
feature ) and instant app plugin ( com.android.instantapp ) as a way to build your instant app. When building your app, you will...
Read more >
FeatureExtension - Android Plugin 3.4.0-dev DSL Reference
The android extension for com.android.feature projects. Creating feature modules is useful when you want to build Android Instant Apps. To learn more about ......
Read more >
Android Dynamic Feature Modules : The Future - Medium
IDE applies the following Gradle plugin to the module's build.gradle file: apply plugin: 'com. · What not to include: · When your dynamic...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found