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

Realm Transformer Output Missing During Android Instrumented Test #7880

Closed
ClockerZadq opened this issue Mar 21, 2024 · 3 comments
Closed

Realm Transformer Output Missing During Android Instrumented Test #7880

ClockerZadq opened this issue Mar 21, 2024 · 3 comments
Labels
Encryption:On Frequency:Always More-information-needed More information needed from the reporter. The issue will autoclose if no more information is given. O-Community Repro:Always SDK-Use:Local T-Bug Waiting-For-Reporter Waiting for more information from the reporter before we can proceed

Comments

@ClockerZadq
Copy link

ClockerZadq commented Mar 21, 2024

How frequently does the bug occur?

Always

Description

This is related to #2936 and #3030

After upgrading to Gradle 7, our build is now issuing a warning about a deprecated feature (the AGP Transformer API). It seems that newer versions have been released to address this however our app is not currently able to support realm 10-x versions.

When running Android instrumented tests a ClassCastException is being thrown at runtime. Several attempts were made to resolve this, like adding kotlin-kapt before realm-android Gradle plugin. The exception only occurs during instrumentation tests.

The output of the realm transformer is being generated to the app/build/intermediates/transforms. Yet the final APK being ran does not contain the generated source.

Stacktrace & log output

java.lang.ClassCastException: my.package.MyRealmObject cannot be cast to io.realm.my_package_MyRealmObjectProxyInterface

Can you reproduce the bug?

Always

Reproduction Steps

in app/build.gradle
androidTestImplementation project(":app")

Version

6.1.0 up to 10.11.1

What Atlas App Services are you using?

Local Database only

Are you using encryption?

Yes

Platform OS and version(s)

Android 10-13

Build environment

  • Android Studio Electric Eel
  • Gradle 7.5.1 and AGP 7.4.0
  • JDK 11
  • Kotlin 1.7.21
Copy link

sync-by-unito bot commented Mar 21, 2024

➤ PM Bot commented:

Jira ticket: RJAVA-1254

@kneth
Copy link
Contributor

kneth commented Apr 12, 2024

We have a fix in Realm Java v10.16.0 of AGP. Please try to upgrade.

@sync-by-unito sync-by-unito bot added More-information-needed More information needed from the reporter. The issue will autoclose if no more information is given. Waiting-For-Reporter Waiting for more information from the reporter before we can proceed labels Apr 12, 2024
Copy link

This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 27, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Encryption:On Frequency:Always More-information-needed More information needed from the reporter. The issue will autoclose if no more information is given. O-Community Repro:Always SDK-Use:Local T-Bug Waiting-For-Reporter Waiting for more information from the reporter before we can proceed
Projects
None yet
Development

No branches or pull requests

2 participants