Closed koneksa-sunny closed 1 week ago
➤ PM Bot commented:
Jira ticket: RCORE-2265
Note that if I change some other non-primary-key field in that class from String to UUID, I don't get the exception, but the migrationBlock is still not called and my app crashes for other reasons since it's expecting that field to be populated.
@koneksa-sunny which SchemaMode are you using when opening the realm?
I found an error that would produce the issue that you report. It is fixed by #8046. But it would require that no migration function is supplied as the codeline with the assertion is only hit if there is no migration function (or if the SchemaMode is additive changes only). So in order to fix your issue, I would look for ways that the migration function could be missing in your application code.
@jedelbo where is SchemaMode configured or set?
SDK and version
SDK : Swift Version: 10.33.0
Observations
Crash log / stacktrace
Steps & Code to Reproduce
I changed my primary key type from String to UUID OLD:
NEW:
configuration: