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.

Realm Java 5.4.1 crashes at buildtime when using Android Gradle Plugin 2.3.1

See original GitHub issue

Goal

I’m new in Realm. I tried to use Realm plugin version 5.4.1. When I tried to syn gradle dependencies, it’s successful but got error when tried to build my project. I tried snapshoot version as explained here

Expected Results

?

Actual Results

Error:Execution failed for task ‘:app:transformClassesWithRealmTransformerForNormalDebug’.

com.android.build.gradle.BaseExtension.getDefaultConfig()Lcom/android/build/gradle/internal/dsl/DefaultConfig;

Steps & Code to Reproduce

Create a new project and add realm version 5.4.1 plugin in my project gradle config

buildscript {

repositories {
    google()
    jcenter()
    maven {
        url 'http://oss.jfrog.org/artifactory/oss-snapshot-local'
    }
}
dependencies {
    classpath 'com.android.tools.build:gradle:2.3.1'
    classpath "io.realm:realm-gradle-plugin:5.4.1"

// classpath “io.realm:realm-gradle-plugin:5.5.0-SNAPSHOT” // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files } }

in my app module gradle

apply plugin: ‘com.android.application’ apply plugin: ‘realm-android’

Code Sample

> Your code here. Bigger samples should ideally be as separate Android Studio project, 
> in gists/repositories or privately at help@realm.io)

Version of Realm and tooling

Realm version(s): 5.4.1

Realm sync feature enabled: no

Android Studio version: 3…0.1

Which Android version and device: ?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:27 (15 by maintainers)

github_iconTop GitHub Comments

1reaction
dacaoyuancommented, Sep 17, 2018

implementation ‘io.realm:realm-android-library:3.4.0’

0reactions
cmelchiorcommented, Jan 4, 2021

This could point to the fact that the minimum version of the build gradle tools we support is higher than we think. We should investigate this and document it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Known issues with Android Studio and Android Gradle Plugin
This section describes known issues that exist in the latest stable version of Android Studio. Error when rendering Compose Preview. Starting with Android...
Read more >
failed to apply plugin 'realm-android' - You.com | The Search ...
I am working on Android studio project and I have trouble with realm library ... Java 5.4.1 crashes at buildtime when using Android...
Read more >
Failed to apply plugin [id 'com.android.application']
Android Gradle Plugin 7 requires Java 11. use short key Ctr+Alt+Shift+S or Go to File > Project Structure and change JDK location to...
Read more >
Realm: Create reactive mobile apps in a fraction ... - MongoDB
Realm is installed as a Gradle plugin. Step 1: Add the class path dependency to the project level build.gradle file.
Read more >
Create reactive mobile apps in a fraction of the time - Realm
Android Studio >= 0.8.6 — to use Realm from Eclipse, see below. ... Realm generates a proxy class for each RealmObject at compile...
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