Thanks for your effort @gerrit. Should your second line be like this?
if ( snapshot.record['_inFlightAttributes'][key] != null
The problem here is that _inFlightAttributes contains only regular attributes, not relationships. In my example above, i am overriding the methods you’ve pointed out to, i am not using _inFlightAttributes explicitly to keep bodies of serialize* methods uniform, but if you look at hasKeyChanged, you will see that this hash is used there, it is just not enough