-
Notifications
You must be signed in to change notification settings - Fork 167
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
[Bug]: Obscure exception when opening a Realm with readonly: true and models mismatching the schema #2619
Comments
Hey, this looks like an issue with the schema not matching the models. We should definitely handle this error better, but you can probably work around it by making sure your c# models match exactly the schema of the Realm you're opening. Typically, the SDK would just update the Realm schema, but since you're opening it as read-only, it is not allowed to write to the file. Then, when it tries to lookup the table for a particular class, it fails because that table doesn't exist. |
Same problem with 10.4.1 |
As I explained above, this issue is expected. The error message could be better, but you can't open a readonly Realm with models that don't match the schema. |
This is a Core bug - reported it here: realm/realm-core#4901. |
Hi @nirinchev , sorry i write about 10.4.1 before see you answer. Thanks for attention at weekend. But, both programs call same DLL that contains Schema. I forget mention that this app has working with other dll that use SYNC to users specific data. Thanks for attention |
➤ Nikola Irinchev commented: Reopening because it might after all be an SDK issue. I'll investigate. |
What happened?
I have a realm .Net Standard project shared by a Core 3.1 program and a Xamarin UWP program.
When called in Xamarin i receive this error.
null
Exception backtrace:
Repro steps
Call in Xamarin with encrypted Key and readonly . This work in .Net Core 3.1
Version
10.5.0
What SDK flavour are you using?
Local Database only
What type of application is this?
Xamarin
Client OS and version
Code snippets
Stacktrace of the exception/crash you're getting
Relevant log output
The text was updated successfully, but these errors were encountered: