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

Nullable embedded schema behaves differently on Realm 12 and 11 #6280

Closed
andreyukD opened this issue Nov 24, 2023 · 4 comments · Fixed by #6295
Closed

Nullable embedded schema behaves differently on Realm 12 and 11 #6280

andreyukD opened this issue Nov 24, 2023 · 4 comments · Fixed by #6295

Comments

@andreyukD
Copy link

andreyukD commented Nov 24, 2023

How frequently does the bug occur?

Always

Description

Realm 11.9.0 and 12.3.1 (I suppose it since 12.0.0) have different behavior when setting the embedded object field to null.
While 11.9.0 allows us to do it, 12.3.1 doesn't set null to an object field. Will it be fixed, or are these new validation constraints?

Stacktrace & log output

No response

Can you reproduce the bug?

Always

Reproduction Steps

I've created an example to show the difference between Realm 12.3.1 and 11.9.0.

https://github.com/andreyukD/reproduce-realmjs-issue (branch v12-3-1)

Starting point was npx create-expo-app MyAwesomeRealmApp --template @realm/expo-template

I've added a new field items in Task schema

commit with 12.3.1 - andreyukD/reproduce-realmjs-issue@8270070
commit with 11.9.0 - andreyukD/reproduce-realmjs-issue@b1ce350

v11-9-0.mp4
v12-3-1.mp4

Version

12.3.1 / 11.9.0

What services are you using?

Local Database only

Are you using encryption?

No

Platform OS and version(s)

macOS 14.0

Build environment

Which debugger for React Native: ..

Cocoapods version

No response

@andreyukD
Copy link
Author

Hi Realm team, any news on this issue? Thanks!

@kneth
Copy link
Contributor

kneth commented Dec 1, 2023

@andreyukD

First, sorry for the late reply. Second, thank you for the bug request. Unfortunately we have had a chance to investigate it yet, but I will bring it up with the next early next week.

@andreyukD
Copy link
Author

andreyukD commented Dec 28, 2023

Can confirm that bug was fixed in Realm v12.5.0
andreyukD/reproduce-realmjs-issue@93e37e5

thanks a lot!

@elle-j
Copy link
Contributor

elle-j commented Dec 28, 2023

Great, thanks @andreyukD 👍

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants