-
-
Notifications
You must be signed in to change notification settings - Fork 24
Description
Target branch: release-0.9.x
Observed behavior
When the serialization process serializes app models into the store, it either creates new Store records or updates existing Store records for those models. When it creates new Store records, it properly sets _self_ref_fk which should store the value of a self-referential foreign key field that exists on the model. When the Store record already exists for the app model, it does not update _self_ref_fk, meaning if the app model's self-referential FK's value changed, the Store would not reflect that.
Expected behavior
The StoreUpdate streaming transform class should properly update _self_ref_fk regardless of whether the Store record is being created or updated.
Tests should be written/updated to ensure that this happens.
User-facing consequences
The primary consumer of Morango, Kolibri, does have models with self-referential FKs, but there isn't a use case where these would be updated. Although, this would cause an issue in the future if it did.
AI usage
None