I received this notice from MongoDB Realm Studio 11.1.1
Converting circular structure to JSON → starting at object with constructor ‘Object’ | property ‘embedded_dog_list’ → object with constructor ‘Array’ | index 0 → object with constructor ‘Object’ — property ‘parent_object’ closes the circle
and I am not sure what to do about it. Is it a SDK issue, Realm Studio issue or something else?
There’s a parent Person object with embedded Dog objects
class PersonClass: Object {
@Persisted var embedded_dog_list: List<EmbeddedDogClass>
and the embedded dogs look like this:
class EmbeddedDogClass: EmbeddedObject {
@Persisted var name = ""
@Persisted var parent_object: AnyRealmValue = .none
@Persisted var linked_city: CityClass!
and the City class
class CityClass: Object {
@Persisted(originProperty: "linked_city") var linkedEmbeddedDogs: LinkingObjects<EmbeddedDogClass>
The idea here is the Persons have dogs. At the same time I want to know a person via the dog in a city. e.g. I can pull up a city, and get a list of dogs in that city, and also, through the parent_object field, know their person. (There are different types of owners, Person being one of them, which is why I used AnyRealmValue)
Any suggestions on what I am doing to cause that message and how to fix?