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

[RLM_ERR_UNSUPPORTED_FILE_FORMAT_VERSION]: Database has an unsupported version (9) and cannot be upgraded #1808

Open
fngbala-luna opened this issue Jul 11, 2024 · 5 comments

Comments

@fngbala-luna
Copy link

How frequently does the bug occur?

Sometimes

Description

Hi,
Some of our users are experiencing a crash when trying to run our app.

As I understand it, it's because the realm file use an unsuported version (number 9 according to the stack trace).

I think I have the crash starting from the Realm kotlin SDK version 1.16.0.
The first version of the SDK used in the project is 1.11.1.

Anyone knows what might cause this crash and how to fix it ?

One of our theory is that the user are updating the app from a "too old" version of realm, What is strange is that the older version is only 1.11.1 (that, according to the release note "Generates Realms with file format v23")

Thanks in advance.

PS : I tried to reproduce it, but never I never managed to make the app crash ... But a "lot" of our users are crashing.

Stacktrace & log output

Fatal Exception: java.lang.RuntimeException
Unable to create application "My_package": java.lang.IllegalStateException: [RLM_ERR_UNSUPPORTED_FILE_FORMAT_VERSION]: Database has an unsupported version (9) and cannot be upgraded


Caused by java.lang.IllegalStateException: [RLM_ERR_UNSUPPORTED_FILE_FORMAT_VERSION]: Database has an unsupported version (9) and cannot be upgraded
       at io.realm.kotlin.internal.interop.CoreErrorConverter.asThrowable(CoreErrorConverter.kt:47)
       at io.realm.kotlin.internal.interop.realmcJNI.realm_open(realmcJNI.java)
       at io.realm.kotlin.internal.interop.realmc.realm_open(realmc.java:434)
       at io.realm.kotlin.internal.interop.RealmInterop.realm_open(RealmInterop.kt:237)
       at io.realm.kotlin.internal.ConfigurationImpl.openRealm$lambda$0(ConfigurationImpl.java:109)
       at io.realm.kotlin.internal.interop.NativePointerKt.use(NativePointer.kt:53)
       at io.realm.kotlin.internal.ConfigurationImpl.openRealm$suspendImpl(ConfigurationImpl.java:108)
       at io.realm.kotlin.internal.ConfigurationImpl.openRealm(ConfigurationImpl.java:100)
       at io.realm.kotlin.internal.RealmImpl$1.invokeSuspend(RealmImpl.kt:133)
       at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
       at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:104)
       at kotlinx.coroutines.EventLoopImplBase.processNextEvent(EventLoop.common.kt:277)
       at kotlinx.coroutines.BlockingCoroutine.joinBlocking(BlockingCoroutine.java:95)
       at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking(BuildersKt__Builders.kt:69)
       at kotlinx.coroutines.BuildersKt.runBlocking(Builders.kt:1)
       at io.realm.kotlin.internal.platform.CoroutineUtilsSharedJvmKt.runBlocking(CoroutineUtilsSharedJvm.kt:22)
       at io.realm.kotlin.internal.platform.CoroutineUtilsSharedJvmKt.runBlocking$default(CoroutineUtilsSharedJvm.kt:21)
       at io.realm.kotlin.internal.RealmImpl.<init>(RealmImpl.kt:115)
       at io.realm.kotlin.internal.RealmImpl.<init>(RealmImpl.kt:133)
       at io.realm.kotlin.internal.RealmImpl$Companion.create$io_realm_kotlin_library(RealmImpl.kt:318)
       at io.realm.kotlin.Realm$Companion.open(Realm.java:83)

Can you reproduce the bug?

No

Reproduction Steps

No response

Version

1.16.0

What Atlas App Services are you using?

Local Database only

Are you using encryption?

No

Platform OS and version(s)

Android (Min SDK 26)

Build environment

Android Studio version: ...
Android Build Tools version: ...
Gradle version: ...

Copy link

sync-by-unito bot commented Jul 11, 2024

➤ PM Bot commented:

Jira ticket: RKOTLIN-1113

@fngbala-luna
Copy link
Author

Hi 👋
Can someone help me here ?

@rorbech
Copy link
Contributor

rorbech commented Jul 17, 2024

Hi @fngbala-luna. Seems like you might have been hit by realm/realm-core#7747. We are working on a release that includes a fix for that. Can you confirm that you are in fact compating the realm files?

@nirinchev nirinchev added the More-information-needed More information needed from the reporter. The issue will autoclose if no more information is given. label Jul 22, 2024
@sync-by-unito sync-by-unito bot added the Waiting-For-Reporter Waiting for more information from the reporter before we can proceed label Jul 22, 2024
@fngbala-luna
Copy link
Author

Hi, thanks for your answer.

Not sure I am compating the realm files. Unless it's done by default ?

@github-actions github-actions bot added Needs-Attention Reporter has responded. Review comment. and removed 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 Jul 25, 2024
@sync-by-unito sync-by-unito bot removed the Needs-Attention Reporter has responded. Review comment. label Aug 1, 2024
@fngbala-luna
Copy link
Author

Hi,
Any news on the issue ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants